Skip to content

Commit

Permalink
merge branch.sql
Browse files Browse the repository at this point in the history
  • Loading branch information
Changaco committed Jan 11, 2025
1 parent abaa38e commit 13018da
Show file tree
Hide file tree
Showing 4 changed files with 116 additions and 106 deletions.
104 changes: 0 additions & 104 deletions sql/branch.sql

This file was deleted.

12 changes: 11 additions & 1 deletion sql/currencies.sql
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,17 @@ CREATE TYPE currency AS ENUM (
'EUR', 'USD',
'AUD', 'BGN', 'BRL', 'CAD', 'CHF', 'CNY', 'CZK', 'DKK', 'GBP', 'HKD', 'HRK',
'HUF', 'IDR', 'ILS', 'INR', 'ISK', 'JPY', 'KRW', 'MXN', 'MYR', 'NOK', 'NZD',
'PHP', 'PLN', 'RON', 'RUB', 'SEK', 'SGD', 'THB', 'TRY', 'ZAR'
'PHP', 'PLN', 'RON', 'RUB', 'SEK', 'SGD', 'THB', 'TRY', 'ZAR',
'AED', 'AFN', 'ALL', 'AMD', 'ANG', 'AOA', 'ARS', 'AWG', 'AZN', 'BAM', 'BBD',
'BDT', 'BIF', 'BMD', 'BND', 'BOB', 'BSD', 'BWP', 'BYN', 'BZD', 'CDF', 'CLP',
'COP', 'CRC', 'CVE', 'DJF', 'DOP', 'DZD', 'EGP', 'ETB', 'FJD', 'FKP', 'GEL',
'GIP', 'GMD', 'GNF', 'GTQ', 'GYD', 'HNL', 'HTG', 'JMD', 'KES', 'KGS', 'KHR',
'KMF', 'KYD', 'KZT', 'LAK', 'LBP', 'LKR', 'LRD', 'LSL', 'MAD', 'MDL', 'MGA',
'MKD', 'MMK', 'MNT', 'MOP', 'MUR', 'MVR', 'MWK', 'MZN', 'NAD', 'NGN', 'NIO',
'NPR', 'PAB', 'PEN', 'PGK', 'PKR', 'PYG', 'QAR', 'RSD', 'RWF', 'SAR', 'SBD',
'SCR', 'SHP', 'SLE', 'SOS', 'SRD', 'SZL', 'TJS', 'TOP', 'TTD', 'TWD', 'TZS',
'UAH', 'UGX', 'UYU', 'UZS', 'VND', 'VUV', 'WST', 'XAF', 'XCD', 'XOF', 'XPF',
'YER', 'ZMW'
);
CREATE TYPE currency_amount AS (amount numeric, currency currency);

Expand Down
104 changes: 104 additions & 0 deletions sql/migrations.sql
Original file line number Diff line number Diff line change
Expand Up @@ -3494,3 +3494,107 @@ UPDATE exchange_routes SET is_default_for = 'EUR', is_default = null WHERE netwo

-- migration #179
ALTER TABLE user_secrets ADD COLUMN latest_use date;

-- migration #180
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'AED';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'AFN';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'ALL';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'AMD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'ANG';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'AOA';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'ARS';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'AWG';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'AZN';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'BAM';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'BBD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'BDT';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'BIF';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'BMD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'BND';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'BOB';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'BSD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'BWP';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'BYN';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'BZD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'CDF';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'CLP';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'COP';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'CRC';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'CVE';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'DJF';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'DOP';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'DZD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'EGP';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'ETB';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'FJD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'FKP';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'GEL';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'GIP';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'GMD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'GNF';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'GTQ';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'GYD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'HNL';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'HTG';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'JMD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'KES';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'KGS';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'KHR';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'KMF';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'KYD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'KZT';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'LAK';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'LBP';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'LKR';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'LRD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'LSL';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'MAD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'MDL';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'MGA';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'MKD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'MMK';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'MNT';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'MOP';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'MUR';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'MVR';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'MWK';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'MZN';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'NAD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'NGN';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'NIO';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'NPR';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'PAB';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'PEN';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'PGK';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'PKR';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'PYG';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'QAR';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'RSD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'RWF';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'SAR';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'SBD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'SCR';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'SHP';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'SLE';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'SOS';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'SRD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'SZL';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'TJS';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'TOP';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'TTD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'TWD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'TZS';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'UAH';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'UGX';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'UYU';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'UZS';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'VND';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'VUV';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'WST';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'XAF';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'XCD';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'XOF';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'XPF';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'YER';
ALTER TYPE currency ADD VALUE IF NOT EXISTS 'ZMW';
INSERT INTO app_conf VALUES ('fixer_access_key', 'null'::jsonb) ON CONFLICT (key) DO NOTHING;
2 changes: 1 addition & 1 deletion sql/schema.sql
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ COMMENT ON EXTENSION pg_stat_statements IS 'track execution statistics of all SQ

-- database metadata
CREATE TABLE db_meta (key text PRIMARY KEY, value jsonb);
INSERT INTO db_meta (key, value) VALUES ('schema_version', '179'::jsonb);
INSERT INTO db_meta (key, value) VALUES ('schema_version', '180'::jsonb);


-- app configuration
Expand Down

0 comments on commit 13018da

Please sign in to comment.