diff options
author | Christian Grothoff <christian@grothoff.org> | 2023-07-28 12:21:28 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2023-07-28 12:21:28 +0200 |
commit | c93ce9ea2eb16a91422b8101fecd8c491c7e93b7 (patch) | |
tree | 073a5d3dc35d410faa3bc098291eab108e63975a /src/exchangedb/exchange_do_age_withdraw.sql | |
parent | 571d43cef3732ed6f491d91a9e767a80008edeb1 (diff) | |
download | exchange-c93ce9ea2eb16a91422b8101fecd8c491c7e93b7.tar.xz |
-fix type defs
Diffstat (limited to 'src/exchangedb/exchange_do_age_withdraw.sql')
-rw-r--r-- | src/exchangedb/exchange_do_age_withdraw.sql | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/src/exchangedb/exchange_do_age_withdraw.sql b/src/exchangedb/exchange_do_age_withdraw.sql index e76d4ba75..ce257a8d9 100644 --- a/src/exchangedb/exchange_do_age_withdraw.sql +++ b/src/exchangedb/exchange_do_age_withdraw.sql @@ -16,7 +16,7 @@ -- @author Özgür Kesim CREATE OR REPLACE FUNCTION exchange_do_age_withdraw( - IN amount_with_fee TALER_AMOUNT, + IN amount_with_fee taler_amount, IN rpub BYTEA, IN rsig BYTEA, IN now INT8, @@ -38,8 +38,8 @@ AS $$ DECLARE reserve_gc INT8; difference RECORD; - balance TALER_AMOUNT; - new_balance TALER_AMOUNT; + balance taler_amount; + new_balance taler_amount; not_before date; earliest_date date; BEGIN @@ -104,9 +104,9 @@ required_age=0; -- Check reserve balance is sufficient. SELECT * -INTO +INTO difference -FROM +FROM amount_left_minus_right( balance ,amount_with_fee); @@ -114,7 +114,7 @@ FROM balance_ok = difference.ok; IF NOT balance_ok -THEN +THEN RETURN; END IF; @@ -166,6 +166,5 @@ END IF; END $$; -COMMENT ON FUNCTION exchange_do_age_withdraw(TALER_AMOUNT, BYTEA, BYTEA, INT8, INT8, BYTEA, INT2, INT2, BYTEA[], INT8[], BYTEA[]) +COMMENT ON FUNCTION exchange_do_age_withdraw(taler_amount, BYTEA, BYTEA, INT8, INT8, BYTEA, INT2, INT2, BYTEA[], INT8[], BYTEA[]) IS 'Checks whether the reserve has sufficient balance for an age-withdraw operation (or the request is repeated and was previously approved) and that age requirements are met. If so updates the database with the result. Includes storing the blinded planchets and denomination signatures, or signaling conflict'; - |