diff options
author | Christian Grothoff <christian@grothoff.org> | 2024-07-17 23:54:30 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2024-07-29 12:18:46 +0200 |
commit | db68289fcf9a8db240a98a970696b2779d442f9e (patch) | |
tree | 1fbff3309362af049a1354304c086316071b3657 /src/exchangedb/pg_select_kyc_attributes.c | |
parent | 4716fe3926d3ac32a6d304b992d092075dc1af7b (diff) | |
download | exchange-db68289fcf9a8db240a98a970696b2779d442f9e.tar.xz |
-SQL fixes
Diffstat (limited to 'src/exchangedb/pg_select_kyc_attributes.c')
-rw-r--r-- | src/exchangedb/pg_select_kyc_attributes.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/src/exchangedb/pg_select_kyc_attributes.c b/src/exchangedb/pg_select_kyc_attributes.c index 99ac43b3e..5a5e99a35 100644 --- a/src/exchangedb/pg_select_kyc_attributes.c +++ b/src/exchangedb/pg_select_kyc_attributes.c @@ -81,7 +81,7 @@ get_attributes_cb (void *cls, void *enc_attributes; char *provider; struct GNUNET_PQ_ResultSpec rs[] = { - GNUNET_PQ_result_spec_string ("provider", + GNUNET_PQ_result_spec_string ("provider_name", &provider), GNUNET_PQ_result_spec_timestamp ("collection_time", &collection_time), @@ -138,12 +138,14 @@ TEH_PG_select_kyc_attributes ( PREPARE (pg, "select_kyc_attributes", "SELECT " - " provider" - ",collection_time" - ",expiration_time" - ",encrypted_attributes" - " FROM kyc_attributes" - " WHERE h_payto=$1"); + " lp.provider_name" + ",ka.collection_time" + ",ka.expiration_time" + ",ka.encrypted_attributes" + " FROM kyc_attributes ka" + " JOIN legitimization_processes lp" + " USING (legitimization_process_serial_id)" + " WHERE ka.h_payto=$1"); qs = GNUNET_PQ_eval_prepared_multi_select ( pg->conn, "select_kyc_attributes", |