2015-11-10 22:31:53 +08:00
|
|
|
-- Create a conf table
|
2015-11-10 22:36:57 +08:00
|
|
|
CREATE TABLE conf (key TEXT PRIMARY KEY, values_json TEXT NOT NULL);
|
2015-11-10 22:31:53 +08:00
|
|
|
INSERT INTO conf VALUES ('cds', '{"Manolo Escobar": {"El Limonero":"En stock", "Viva el vino":"Sin stock"}}');
|
|
|
|
|
|
|
|
-- Test key retrieval
|
|
|
|
SELECT cdb_geocoder_server._get_conf('cds');
|
|
|
|
|
|
|
|
-- Test no key exception
|
|
|
|
SELECT cdb_geocoder_server._get_conf('no existe');
|
|
|
|
|
|
|
|
-- Drop conf table
|
|
|
|
DROP TABLE conf;
|