[libgda] GdaDataProxy: better filter error reporting
- From: Vivien Malerba <vivien src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libgda] GdaDataProxy: better filter error reporting
- Date: Sun, 3 Jun 2012 16:03:54 +0000 (UTC)
commit 946247de0f5d9b9d8e4092710675d1b6b68b3c79
Author: Vivien Malerba <malerba gnome-db org>
Date: Sun Jun 3 18:01:53 2012 +0200
GdaDataProxy: better filter error reporting
libgda/gda-data-proxy.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/libgda/gda-data-proxy.c b/libgda/gda-data-proxy.c
index b091a7c..736055d 100644
--- a/libgda/gda-data-proxy.c
+++ b/libgda/gda-data-proxy.c
@@ -3116,10 +3116,12 @@ apply_filter_statement (GdaDataProxy *proxy, GError **error)
gda_sql_statement_free (sqlst);
/* execute statement */
- filtered_rows = gda_connection_statement_execute_select (vcnc, stmt, NULL, NULL);
+ GError *lerror = NULL;
+ filtered_rows = gda_connection_statement_execute_select (vcnc, stmt, NULL, &lerror);
if (!filtered_rows) {
g_set_error (error, GDA_DATA_PROXY_ERROR, GDA_DATA_PROXY_FILTER_ERROR,
- "%s", _("Error in filter expression"));
+ _("Error in filter expression: %s"), lerror && lerror->message ? lerror->message : _("No detail"));
+ g_clear_error (&lerror);
proxy->priv->force_direct_mapping = FALSE;
gda_vconnection_data_model_remove (GDA_VCONNECTION_DATA_MODEL (vcnc), "proxy", NULL);
goto clean_previous_filter;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]