aboutsummaryrefslogtreecommitdiff
path: root/data/sql/proj_db_table_defs.sql
AgeCommit message (Collapse)Author
2022-01-04Database: update to EPSG 10.044Even Rouault
2021-09-28Add a mapping for versioned authorities, so that one can use IAU:xxxx or ↵Even Rouault
IAU_2015:xxxx transparently
2021-09-28Database: add check for Orthographic conversionEven Rouault
2021-09-28Database: add some hand made entries earlyEven Rouault
2021-09-17Database: add a 'anchor' field to geodetic_datum and vertical_datum tablesEven Rouault
Update database layout version number to 1.2 consequently This new capability will be used by IAU planetary CRS (refs #2601)
2021-05-24Database: decrease DB size by using WITHOUT ROWID tablesEven Rouault
None of our tables are indexed by a INTEGER PRIMARY KEY, but most of them are by a (auth_name, code) primary key. Consequently they can benefit from being created as WITHOUT ROWID tables (https://sqlite.org/withoutrowid.html), which avoids an index to be created on the rowid we don't use. WITHOUT ROWID is a feature added in SQLite 3.8.2, so as our baseline is 3.11, we can use it. This decreases the DB size from 7,749,632 to 7,229,440 bytes, without any measurable consequence on performance.
2021-04-23Database: update to EPSG v10.019Even Rouault
Non-trivial updates: - some vertical CRS are now encoded as DerivedVerticalCRS. e.g EPSG:8228 "NAVD88 height (ft)", with base EPSG:5703 "NAVD88 height". As we don't have support in our PROJ db model for DerivedVerticalCRS, modify the import script to 'resolve' the derivation up to the original datum. - Method EPSG:1069 'Change of Vertical Unit' is no longer used. It is replaced by a generic-purpose EPSG:1104 method that doesn't take any conversion factor. And generic conversions EPSG:7812 and EPSG:7813 are now used in concatenated operations, which require code changes as well.
2021-04-06Database: nullify auth_name, code of usage tableEven Rouault
We never select by those columns, so don't set them. Reduce from 8.4 to 7.9 MB. Upgrade the minor version of the database layout. (that database can still be read by PROJ 8.0)
2021-04-04Database: decrease db size by using a INTEGER_OR_TEXT data type on codesEven Rouault
Most codes (especially *all* in EPSG) are integers. As integers are stored as variable-length in the db, it is preferable to store them as such when possible. So use a special INTEGER_OR_TEXT data type. This is a "non-standard" type declaration, but this is perfectly legal as SQLite is loosely typed. As this declaration contains the string INT, it is assigned INTEGER affinity. Which means that values provided either as text (that contains integer value) or integer will be stored as integers, whereas text values will be stored as text. See paragraph 3 and 3.1 of https://www.sqlite.org/datatype3.html. The "INTEGER_OR_TEXT" name is a hint for the user, and software like GDAL (>= 3.3) to expose the column as string... The effect of using this rather than TEXT is making the DB size go from 9 MB to 8.4. There is no need to change the DATABASE.LAYOUT version numbering as this is completely forward and backward compatible.
2021-04-04Database: add missing column type specifir for method_name in ↵Even Rouault
grid_transformation and other_transformation. No practical impact
2021-03-26Build: simplify proj.db generation (#2605)Even Rouault
- change foreign key check, so that it is enabled outside of the transaction where we insert things, and can make the sqlite3 process fail in case of violations, without the postcheck done in the autoconf build - autoconf and cmake builds: simplification related to the above (which also means that cmake builds now have the fkey check, which was omitted until now)
2021-03-19Database: relax trigger check when inserting a conversion to accept any ↵Even Rouault
conversion method in the PROJ namespace Helps for example to use CRS definitions using the non-EPSG codified Sinusoidal method.
2021-03-11Database: Additions to the norwegian NKG2020 transformation (#2548)Sveinung Himle
* Correction grid NKG:ETRF14 to EPSG:7922 * Added NKG:ITRF_TO_NO GIE test * Correction grid no_kv_NKGETRF14_EPSG7922_2000 added to grid_alternatives.sql * proj_method 'velocity_grid' added in check_grid_alternatives_proj_method. NKG velocity grid added to grid_alternatives.sql Co-authored-by: Even Rouault <even.rouault@spatialys.com>
2020-12-04Database: fix building proj.db with SQLite built with -DSQLITE_DQS=0Even Rouault
That is the option to make SQLite reject misuses of double quotes instead of single quotes. Most SQLite builds are forgiving, but some forks proposing a CMake build system default to SQLITE_DQS=0
2020-10-23Database: add interpolation_crs_auth_name and interpolation_crs_code columns ↵Even Rouault
to other_transformation table
2020-10-23Database: import ESRI VERTCS that uses a (geodetic) datum to express ↵Even Rouault
ellipsoidal height
2020-10-11Database: add a frame_reference_epoch column in vertical_datum to be able to ↵Even Rouault
handle dynamic vertical datums, and instanciate them properly from database
2020-10-08Database: import datum ensemble accuracy and members (but do not use them)Even Rouault
2020-10-06Database: add a reference_frame_epoch column to the geodetic_datum for ↵Even Rouault
dynamic datums, but not yet used
2020-10-06Database: "minimal" update to EPSG v10.003Even Rouault
Content mostly unchanged since v9.9 This update is "minimal" in that it mostly reflects the removal of the 'area' table, replaced now by 'extent', 'scope' and 'usage' Other new aspects of EPSG v10 are left aside.
2020-05-24Database: add a same_source_target_crs column to supersession tableEven Rouault
This is in preparation for EPSG 9.8.11 import that supersedes a number of grid transformation for US transformations, but the superseded and replacement transformations don't operate on the same (source_crs, target_crs), which is a bit weird. So in that situation, ignores the supersession.
2020-05-15Database: add index on alias_name(code)Even Rouault
2020-03-12Add proj_get_units_from_database() (fixes #2004)Even Rouault
2020-02-26Database: update to EPSG v9.8.7Even Rouault
2020-02-05Fix performance issue, affecting projinfo EPSG:7842Even Rouault
Fixes #1913 AuthorityFactory::createBetweenGeodeticCRSWithDatumBasedIntermediates() issued a complex SQL query that pushes the SQLite3 query plan optimizer to its limits. Was working reasonably with sqlite 3.11, but not with later versions. So put less constraints in the main query and do post-processing checks and auxiliary requests to avoid such issues. For some unknown reason, this slightly slows down a bit execution time of the whole test_cpp_api binary (~ 10%), but couldn't come with something better, despite trying many variations of the main SQL query. It seems that in the general case the non-filter LEFT JOIN on the supersession table helped, except on this EPSG:7842 case.
2020-01-29Add EPSG records for 'Geocentric translation by Grid Interpolation (IGN)' ↵Even Rouault
(gr3df97a.txt) and map them to new +proj=xyzgridshift
2020-01-29Make it possible to use grids from the CDN by their 'old name' even if not ↵Even Rouault
in the EPSG/grid_transformation table
2020-01-25Implement RFC 5Even Rouault
2020-01-23Database: add a geoid_like value for proj_method column of ↵Even Rouault
grid_alternatives, fix related entries and simplify/robustify logic to deal with EPSG 'Geographic3D to GravityRelatedHeight' methods
2020-01-22Database: update to EPSG v9.8.6Even Rouault
Fixes #1867
2019-12-21proj_db_table_defs.sql: rewrite some trigger checks as normal table ↵Even Rouault
CONSTRAINT CHECK
2019-11-18Database: add a publication_date column to geodetic_datum and vertical_datumEven Rouault
Populated from realization_epoch column from EPSG The 'publication_date' naming is from OGC Topic 2, and hasn't been yet adopted by the EPSG dataset. See http://docs.opengeospatial.org/as/18-005r4/18-005r4.html , Annex G, clause 11 and https://32zn56499nov99m251h4e9t8-wpengine.netdna-ssl.com/wp-content/uploads/2019/09/EPSG-relational-data-model-changes_2019-09-18.pdf
2019-11-17createOperations(): remove the concept of geodetic_datum_preferred_hubEven Rouault
This was introduced in 63857c92b271bbcd10df0a032304982011acb2a9. Due to the fix done in the previous commit, we can mostly revert the above commit. We just keep the added tests and the custom WGS 84<-->WGS 84 (Gxxxx) null transformations.
2019-11-02Add a geoid_model name in database, use GEOIDMODEL for transformations, add ↵Even Rouault
a proj_create_vertical_crs_ex()
2019-10-27Database: add an auxiliary concatenated_operation_step table to allow ↵Even Rouault
arbitrary number of steps (fixes #1632) EPSG:9103 (NAD27 to ITRF2014 (1)) is now handled. Note:EPSG:9104 (NAD27 to ITRF2014 (2)) is not currently, since it uses for step EPSG:8861 (NAD83(HARN) to NAD83(FBN) (1)) an unsupported transformation method (NADCON5 (3D), EPSG:1075).
2019-09-12Coordinate transformation: improve transformations from/to WGS84 (Gxxxx)Even Rouault
Currently very few transformations from/to WGS84 (Gxxxx) are registered in the EPSG database, and there isn't even transformations between WGS84 EPSG:4326 and those ones. Consequently transformations to those realizations often ended up as no-operation, whereas going through WGS84 EPSG:4326 will bring more meaningful results. So register those EPSG:4326<-->WGS 84 (Gxxx) null transformations, and when having WGS 84 (Gxxx) as source/target, consider EPSG:4326 as an intermediate. This change has no effect on the existing direct transformations from/to WGS 84 (Gxxx).
2019-04-22Database: add checks to verify consistency of deprecated flagEven Rouault
2019-04-22Database: make conversion & helmert_transformation updatable viewsEven Rouault
- Transform conversion as a view, and when inserting into it, actually insert into 3 tables: conversion_table, conversion_method and conversion_param, so that method and parameter names are not repeated each time. - Similarly for helmert_tranformation, insert into helmert_transformation_tabl and coordinate_operation_method. This reduces the db size from 6 344 704 bytes to 5 853 184 bytes, without significant slowdown for queries.
2019-03-25Database: add operation_version column to coordinate operation tablesEven Rouault
2018-12-06Add API to retrieve non-deprecated equivalent of an objectEven Rouault
2018-12-06Coordinate operation search: add a authority_to_authority_preference table ↵Even Rouault
to restrict and prioritize searches
2018-12-06Take into account supersession information to filter out irrelevant ↵Even Rouault
transformations
2018-11-14Implement RFC 2: Initial integration of "GDAL SRS barn" workEven Rouault
This work mostly consists of: - a C++ implementation of the ISO-19111:2018 / OGC Topic 2 "Referencing by coordinates" classes to represent Datums, Coordinate systems, CRSs (Coordinate Reference Systems) and Coordinate Operations. - methods to convert between this C++ modeling and WKT1, WKT2 and PROJ string representations of those objects - management and query of a SQLite3 database of CRS and Coordinate Operation definition - a C API binding part of those capabilities This is all-in-one squashed commit of the work of https://github.com/OSGeo/proj.4/pull/1040