[GRASS-dev] [GRASS GIS] #3239: DB library and drivers lack bigint (int8) support

#3239: DB library and drivers lack bigint (int8) support
--------------------------+-------------------------
Reporter: martinl | Owner: grass-dev@…
     Type: task | Status: new
Priority: major | Milestone: 7.4.0
Component: Database | Version: unspecified
Keywords: bigint, int8 | CPU: Unspecified
Platform: Unspecified |
--------------------------+-------------------------
GRASS DBMI Library and DB driver lacks support of bigint (int8), see
source:grass/trunk/include/dbmi.h#L78

Currently DB drivers just print warnings like

{{{
WARNING: Column 'pr_' : type int8 (bigint) is stored as integer (4 bytes)
some data may be damaged
}}}

Since bigint is normally used GRASS DB drivers should support it.

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/3239&gt;
GRASS GIS <https://grass.osgeo.org>

#3239: DB library and drivers lack bigint (int8) support
--------------------------+--------------------------
  Reporter: martinl | Owner: grass-dev@…
      Type: task | Status: new
  Priority: major | Milestone: 7.4.0
Component: Database | Version: unspecified
Resolution: | Keywords: bigint, int8
       CPU: Unspecified | Platform: Unspecified
--------------------------+--------------------------
Changes (by turek):

* Attachment "patch64.diff" added.

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/3239&gt;
GRASS GIS <https://grass.osgeo.org>

#3239: DB library and drivers lack bigint (int8) support
--------------------------+--------------------------
  Reporter: martinl | Owner: grass-dev@…
      Type: task | Status: new
  Priority: major | Milestone: 7.4.0
Component: Database | Version: unspecified
Resolution: | Keywords: bigint, int8
       CPU: Unspecified | Platform: Unspecified
--------------------------+--------------------------

Comment (by turek):

I just attached file patch64.diff​ which adds bigint support to DB
library.

In the patch, there is off_t type used for bigint. It should not be used
in such a way since it is intended to represent file sizes.

I used the patch as a quick fix in order to be able to work with 64 OSM
identifiers. It is untested and mainly unfinished. However, it can point a
way to a proper implementation.

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/3239#comment:1&gt;
GRASS GIS <https://grass.osgeo.org>

#3239: DB library and drivers lack bigint (int8) support
--------------------------+--------------------------
  Reporter: martinl | Owner: grass-dev@…
      Type: task | Status: new
  Priority: major | Milestone: 7.8.0
Component: Database | Version: unspecified
Resolution: | Keywords: bigint, int8
       CPU: Unspecified | Platform: Unspecified
--------------------------+--------------------------
Changes (by martinl):

* milestone: 7.4.2 => 7.8.0

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/3239#comment:4&gt;
GRASS GIS <https://grass.osgeo.org>