Class UsingProperties

java.lang.Object
org.postgresql.pljava.example.annotation.UsingProperties
All Implemented Interfaces:
ResultSetProvider, ResultSetProvider.Large

@SQLAction(requires={"propertyExampleAnno","propertyExampleRB"}, install={"WITH expected AS (VALUES (\'adjective\' ::varchar(200), \'avaricious\' ::varchar(200)), (\'noun\', \'platypus\') )SELECT CASE WHEN 2 = count(prop) AND every(prop IN (SELECT expected FROM expected)) THEN javatest.logmessage(\'INFO\', \'get resource passes\') ELSE javatest.logmessage(\'WARNING\', \'get resource fails\') END FROM propertyExampleAnno() AS prop","WITH expected AS (VALUES (\'adjective\' ::varchar(200), \'avaricious\' ::varchar(200)), (\'noun\', \'platypus\') )SELECT CASE WHEN 2 = count(prop) AND every(prop IN (SELECT expected FROM expected)) THEN javatest.logmessage(\'INFO\', \'get ResourceBundle passes\') ELSE javatest.logmessage(\'WARNING\', \'get ResourceBundle fails\') END FROM propertyExampleRB() AS prop"}) public class UsingProperties extends Object implements ResultSetProvider.Large
An example that retrieves a Properties resource, and returns (key,value) rows from it by implementing the ResultSetProvider interface.
Author:
Thomas Hallgren