[libgdamm] SqlBuilder: Added add_field_id().
- From: Murray Cumming <murrayc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libgdamm] SqlBuilder: Added add_field_id().
- Date: Tue, 15 Jun 2010 20:11:14 +0000 (UTC)
commit ea775dbde8a0f27358d9ed24e65a688b16d271d6
Author: Murray Cumming <murrayc murrayc com>
Date: Tue Jun 15 22:11:00 2010 +0200
SqlBuilder: Added add_field_id().
* libgda/src/sqlbuilder.[hg|ccg]: Added add_field_id().
ChangeLog | 6 ++++++
libgda/src/sqlbuilder.ccg | 6 +-----
libgda/src/sqlbuilder.hg | 9 +++------
3 files changed, 10 insertions(+), 11 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 0374f73..e58dd8b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,11 @@
2010-06-15 Murray Cumming <murrayc murrayc com>
+ SqlBuilder: Added add_field_id().
+
+ * libgda/src/sqlbuilder.[hg|ccg]: Added add_field_id().
+
+2010-06-15 Murray Cumming <murrayc murrayc com>
+
Fix the build with libgda git master.
* libgda/src/libgda_methods.defs: Regenerated with h2defs.py.
diff --git a/libgda/src/sqlbuilder.ccg b/libgda/src/sqlbuilder.ccg
index f830e08..aef199e 100644
--- a/libgda/src/sqlbuilder.ccg
+++ b/libgda/src/sqlbuilder.ccg
@@ -48,16 +48,12 @@ SqlBuilder::SqlBuilder(SqlStatementType type)
}
+//TODO: Use _WRAP_METHOD() for these instead now that they are simple.
SqlBuilder::Id SqlBuilder::add_sub_select(const SqlStatement& sqlst)
{
return gda_sql_builder_add_sub_select(gobj(), const_cast<GdaSqlStatement*>(sqlst.gobj()));
}
-SqlBuilder::Id SqlBuilder::add_id(const Glib::ustring& string)
-{
- return gda_sql_builder_add_id(gobj(), string.c_str());
-}
-
SqlBuilder::Id SqlBuilder::add_expr_as_value(const Glib::RefPtr<DataHandler>& dh, const Value& value)
{
return gda_sql_builder_add_expr_value(gobj(), dh->gobj(), const_cast<GValue*>(value.gobj()));
diff --git a/libgda/src/sqlbuilder.hg b/libgda/src/sqlbuilder.hg
index 736f762..a4e5d49 100644
--- a/libgda/src/sqlbuilder.hg
+++ b/libgda/src/sqlbuilder.hg
@@ -65,12 +65,9 @@ public:
// Expression API:
- /** Defines an expression which may be reused to build other parts of a statement.
- * @param string String to use in the SQL
- *
- * @return The ID of the new expression, or 0 if there was an error.
- */
- Id add_id(const Glib::ustring& string);
+ _WRAP_METHOD(Id add_id(const Glib::ustring& string), gda_sql_builder_add_id)
+
+ _WRAP_METHOD(Id add_field_id(const Glib::ustring& field_name, const Glib::ustring& table_name = Glib::ustring()), gda_sql_builder_add_field_id)
/** Defines an expression in Builder which may be reused to build other parts of a statement.
* @param dh The datahandler to use
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]