[postgis-devel] postgis_version() alias of postgis_full_version() ?

Martin Daly Martin.Daly at cadcorp.com
Thu Dec 15 02:29:59 PST 2005


> Well, I will CC my list of known important PostGIS clients to this  
> response: I am sure at least some of them are already using  
> postgis_version for version switching, so care must be taken, but  
> perhaps these guys can provide some guidance to how they are parsing  
> the string.

We too use postgis_version, but only if postgis_lib_version fails, and do a simple sscanf on the result.  As long as the first part of the returned string was major.minor[.build], our code should be OK.

So, provided that postgis_lib_version remains, we should be OK.  If either postgis_lib_version or postgis_version (iif postgis_lib_version failed) returned any non-blank characters before the "major" number, then we would be in trouble.

M



More information about the postgis-devel mailing list