[libgda/LIBGDA_4.2] GdaVconnectionHub: only update meta data if necessary
- From: Vivien Malerba <vivien src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libgda/LIBGDA_4.2] GdaVconnectionHub: only update meta data if necessary
- Date: Thu, 26 May 2011 18:41:43 +0000 (UTC)
commit 4cf56504bd0ff7e72fca3c3f1a526d49d1045db9
Author: Vivien Malerba <malerba gnome-db org>
Date: Thu May 26 20:37:37 2011 +0200
GdaVconnectionHub: only update meta data if necessary
libgda/sqlite/virtual/gda-vconnection-hub.c | 15 +++++++++------
1 files changed, 9 insertions(+), 6 deletions(-)
---
diff --git a/libgda/sqlite/virtual/gda-vconnection-hub.c b/libgda/sqlite/virtual/gda-vconnection-hub.c
index 06bc17e..3a9da64 100644
--- a/libgda/sqlite/virtual/gda-vconnection-hub.c
+++ b/libgda/sqlite/virtual/gda-vconnection-hub.c
@@ -800,15 +800,18 @@ attach_hub_connection (GdaVconnectionHub *hub, HubConnection *hc, GError **error
gchar *tmp;
GdaMetaStore *store;
GdaMetaContext context;
+ GdaConnectionOptions options;
store = gda_connection_get_meta_store (hc->cnc);
g_assert (store);
-
- /* make sure the meta store is up to date */
- context.table_name = "_tables";
- context.size = 0;
- if (!gda_connection_update_meta_store (hc->cnc, &context, error))
- return FALSE;
+ g_object_get ((GObject*) hc->cnc, "options", &options, NULL);
+ if (! (options & GDA_CONNECTION_OPTIONS_AUTO_META_DATA)) {
+ /* make sure the meta store is up to date */
+ context.table_name = "_tables";
+ context.size = 0;
+ if (!gda_connection_update_meta_store (hc->cnc, &context, error))
+ return FALSE;
+ }
/* add a :memory: database */
if (hc->ns) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]