[anjuta/symbol-db-model] symbol-db: Fixed file symbols query with limit and offset set
- From: Naba Kumar <naba src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [anjuta/symbol-db-model] symbol-db: Fixed file symbols query with limit and offset set
- Date: Thu, 18 Mar 2010 20:45:55 +0000 (UTC)
commit cd2dd555a0fd2b53dbe2c6c47df86649d6999be2
Author: Naba Kumar <naba gnome org>
Date: Thu Mar 18 00:16:59 2010 +0200
symbol-db: Fixed file symbols query with limit and offset set
plugins/symbol-db/symbol-db-engine-queries.c | 22 ++++++++++++++++++++++
1 files changed, 22 insertions(+), 0 deletions(-)
---
diff --git a/plugins/symbol-db/symbol-db-engine-queries.c b/plugins/symbol-db/symbol-db-engine-queries.c
index db3f850..23947b4 100644
--- a/plugins/symbol-db/symbol-db-engine-queries.c
+++ b/plugins/symbol-db/symbol-db-engine-queries.c
@@ -1585,6 +1585,28 @@ symbol_db_engine_get_file_symbols (SymbolDBEngine *dbe,
}
MP_SET_HOLDER_BATCH_STR(priv, param, relative_path, ret_bool, ret_value);
+
+ if (results_limit > 0)
+ {
+ if ((param = gda_set_get_holder ((GdaSet*)dyn_node->plist, "limit")) == NULL)
+ {
+ SDB_UNLOCK(priv);
+ return NULL;
+ }
+
+ MP_SET_HOLDER_BATCH_INT(priv, param, results_limit, ret_bool, ret_value);
+ }
+
+ if (results_offset > 0)
+ {
+ if ((param = gda_set_get_holder ((GdaSet*)dyn_node->plist, "offset")) == NULL)
+ {
+ SDB_UNLOCK(priv);
+ return NULL;
+ }
+
+ MP_SET_HOLDER_BATCH_INT(priv, param, results_offset, ret_bool, ret_value);
+ }
/* execute the query with parametes just set */
data = gda_connection_statement_execute_select (priv->db_connection,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]