Commit 97cf4573 authored by Regina Obe's avatar Regina Obe

Support for PostgreSQL 9.5 use Int64GetDatum instead of UInt64GetDatum for < 9.6

Revise tests to disable outdb first so that error test consitently fails even if default state is to have out db allowed
Closes #4083 for PostGIS 2.5.0
Closes https://github.com/postgis/postgis/pull/240

git-svn-id: http://svn.osgeo.org/postgis/trunk@16569 b70326c6-7e19-0410-871a-916f4a2858ee
parent 4c94d43e
Pipeline #21745799 passed with stage
in 17 minutes and 16 seconds
......@@ -736,8 +736,13 @@ Datum RASTER_bandmetadata(PG_FUNCTION_ARGS)
}
if (bmd2[call_cntr].filesize) {
#if POSTGIS_PGSQL_VERSION > 95
values[6] = UInt64GetDatum(bmd2[call_cntr].filesize);
values[7] = UInt64GetDatum(bmd2[call_cntr].timestamp);
#else /* POSTGIS_PGSQL_VERSION <= 95 */
values[6] = Int64GetDatum(bmd2[call_cntr].filesize);
values[7] = Int64GetDatum(bmd2[call_cntr].timestamp);
#endif
}
else {
nulls[6] = TRUE;
......
SET postgis.enable_outdb_rasters = false;
SELECT count(*) FROM raster_outdb_template;
SELECT DISTINCT ST_BandFileSize(rast) FROM raster_outdb_template;
SELECT DISTINCT ST_BandFileTimestamp(rast) FROM raster_outdb_template;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment