gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-exchange] 71/130: implement missing SQL statement


From: gnunet
Subject: [taler-exchange] 71/130: implement missing SQL statement
Date: Wed, 17 Nov 2021 12:25:19 +0100

This is an automated email from the git hooks/post-receive script.

grothoff pushed a commit to branch master
in repository exchange.

commit 766922f7e9bd5570fd12b663e61f8bd622e51c78
Author: Christian Grothoff <grothoff@gnunet.org>
AuthorDate: Fri Nov 5 13:20:14 2021 +0100

    implement missing SQL statement
---
 contrib/gana                                |  2 +-
 src/exchangedb/plugin_exchangedb_postgres.c | 17 +++++++++++++++--
 2 files changed, 16 insertions(+), 3 deletions(-)

diff --git a/contrib/gana b/contrib/gana
index 8c7d9be4..17555514 160000
--- a/contrib/gana
+++ b/contrib/gana
@@ -1 +1 @@
-Subproject commit 8c7d9be40ba627348da3e01b91b4f1d3cc78631f
+Subproject commit 17555514bd2866e0d45b23e4a1c198415205c8f2
diff --git a/src/exchangedb/plugin_exchangedb_postgres.c 
b/src/exchangedb/plugin_exchangedb_postgres.c
index 66bad461..3340a70d 100644
--- a/src/exchangedb/plugin_exchangedb_postgres.c
+++ b/src/exchangedb/plugin_exchangedb_postgres.c
@@ -1885,6 +1885,19 @@ prepare_statements (struct PostgresClosure *pg)
       "    FROM denominations"
       "    WHERE denom_pub_hash=$2);",
       2),
+    /* used in #postgres_select_withdraw_amounts_by_account() */
+    GNUNET_PQ_make_prepare (
+      "select_above_date_by_reserves_out",
+      "SELECT"
+      " amount_with_fee_val"
+      ",amount_with_fee_frac"
+      " FROM reserves_out"
+      " WHERE reserve_uuid="
+      "   (SELECT reserve_uuid"
+      "      FROM reserves"
+      "     WHERE reserve_pub=$1)"
+      "  AND execution_date > $2;",
+      2),
     /* used in #postgres_lookup_wire_fee_by_time() */
     GNUNET_PQ_make_prepare (
       "lookup_wire_fee_by_time",
@@ -4937,7 +4950,7 @@ withdraw_amount_by_account_cb (void *cls,
   {
     struct TALER_Amount val;
     struct GNUNET_PQ_ResultSpec rs[] = {
-      TALER_PQ_RESULT_SPEC_AMOUNT ("val",
+      TALER_PQ_RESULT_SPEC_AMOUNT ("amount_with_fee",
                                    &val),
       GNUNET_PQ_result_spec_end
     };
@@ -4995,7 +5008,7 @@ postgres_select_withdraw_amounts_by_account (
 
   qs = GNUNET_PQ_eval_prepared_multi_select (
     pg->conn,
-    "select_XXX_FIXME",
+    "select_above_date_by_reserves_out",
     params,
     &withdraw_amount_by_account_cb,
     &wac);

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]