diff options
Diffstat (limited to 'sql/modules/Location.sql')
-rw-r--r-- | sql/modules/Location.sql | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/sql/modules/Location.sql b/sql/modules/Location.sql index c0d57b51..67d197b3 100644 --- a/sql/modules/Location.sql +++ b/sql/modules/Location.sql @@ -19,7 +19,7 @@ $$ DECLARE out_row RECORD; BEGIN FOR out_row IN - SELECT * FROM country ORDER BY id + SELECT * FROM country ORDER BY name LOOP RETURN NEXT out_row; END LOOP; @@ -124,3 +124,14 @@ BEGIN END; $$ language plpgsql; +CREATE TYPE location_result AS ( + id int, + line_one text, + line_two text, + line_three text, + city text, + state text, + country text, + class text +); + |