ST_Raster.getCompressionType

Definition

The ST_Raster.getCompressionType function returns the compression property used to store the data in the ST_Raster. Valid values are as follows:

Syntax

Oracle

getCompressionType()

PostgreSQL

getCompressionType(raster IN ST_RASTER)

SQL Server

getCompressionType()

Returns

Oracle

VARCHAR2

PostgreSQL

Text

SQL Server

NVARCHAR

Parameters

None

Examples

The following queries return the compression type for each raster in the table:

Oracle

SELECT image.raster_id, image.getCompressionType()
FROM FOO t;

T.IMAGE.RASTER_ID T.IMAGE.GETCOMPRESSIONTYPE()
--------------- --------------------------
              2 LZ77
              3 LZ77
             23 JP2
             24 JP2 
             42 LZ77
             43 LZ77

PostgreSQL

SELECT raster_id(image), getCompressionType(image)
FROM foo;

RASTER_ID(IMAGE) GETCOMPRESSIONTYPE(IMAGE)
---------------- -------------------------
               2 LZ77
               3 LZ77
              23 JP2
              24 JP2 
              42 LZ77
              43 LZ77

SQL Server

SELECT image.raster_id, image.getCompressionType()
FROM foo;

IMAGE.RASTER_ID IMAGE.GETCOMPRESSIONTYPE()
--------------- --------------------------
              2 LZ77
              3 LZ77
             23 JP2
             24 JP2 
             42 LZ77
             43 LZ77
6/19/2015