Re: [gnome-db] New patch. Closes bug #68577
- From: Gonzalo Paniagua Javier <gonzalo gnome-db org>
- To: Gnome-db list <gnome-db-list gnome org>
- Subject: Re: [gnome-db] New patch. Closes bug #68577
- Date: Fri, 18 Jan 2002 16:44:02 +0100
Here it goes again.
? M1.awk
? MergeLog.awk
? testlog
Index: doc/C/ChangeLog
===================================================================
RCS file: /cvs/gnome/libgda/doc/C/ChangeLog,v
retrieving revision 1.23
diff -u -r1.23 ChangeLog
--- doc/C/ChangeLog 2002/01/15 12:36:58 1.23
+++ doc/C/ChangeLog 2002/01/18 15:42:42
@@ -1,3 +1,7 @@
+2002-01-17 Gonzalo Paniagua Javier <gonzalo gnome-db org>
+
+ * tmpl/gda-command.sgml: added documentation.
+
2002-01-15 Gonzalo Paniagua Javier <gonzalo gnome-db org>
* libgda-docs.sgml: added parameter information to the providers
Index: doc/C/libgda-sections.txt
===================================================================
RCS file: /cvs/gnome/libgda/doc/C/libgda-sections.txt,v
retrieving revision 1.5
diff -u -r1.5 libgda-sections.txt
--- doc/C/libgda-sections.txt 2002/01/15 23:48:46 1.5
+++ doc/C/libgda-sections.txt 2002/01/18 15:42:42
@@ -237,6 +237,25 @@
</SECTION>
<SECTION>
+<FILE>gda-server-recordset-model</FILE>
+GdaServerRecordsetModelPrivate
+<TITLE>GdaServerRecordsetModel</TITLE>
+gda_server_recordset_model_new
+gda_server_recordset_model_set_field_defined_size
+gda_server_recordset_model_set_field_name
+gda_server_recordset_model_set_field_scale
+gda_server_recordset_model_set_field_gdatype
+gda_server_recordset_model_append_row
+<SUBSECTION Standard>
+GDA_SERVER_RECORDSET_MODEL
+GDA_IS_SERVER_RECORDSET_MODEL
+GDA_TYPE_SERVER_RECORDSET_MODEL
+gda_server_recordset_model_get_type
+GDA_SERVER_RECORDSET_MODEL_CLASS
+GDA_IS_SERVER_RECORDSET_MODEL_CLASS
+</SECTION>
+
+<SECTION>
<FILE>gda-server-recordset</FILE>
GdaServerRecordsetPrivate
<TITLE>GdaServerRecordset</TITLE>
@@ -702,25 +721,6 @@
</SECTION>
<SECTION>
-<FILE>gda-server-recordset-model</FILE>
-GdaServerRecordsetModelPrivate
-<TITLE>GdaServerRecordsetModel</TITLE>
-gda_server_recordset_model_new
-gda_server_recordset_model_set_field_defined_size
-gda_server_recordset_model_set_field_name
-gda_server_recordset_model_set_field_scale
-gda_server_recordset_model_set_field_gdatype
-gda_server_recordset_model_append_row
-<SUBSECTION Standard>
-GDA_SERVER_RECORDSET_MODEL
-GDA_IS_SERVER_RECORDSET_MODEL
-GDA_TYPE_SERVER_RECORDSET_MODEL
-gda_server_recordset_model_get_type
-GDA_SERVER_RECORDSET_MODEL_CLASS
-GDA_IS_SERVER_RECORDSET_MODEL_CLASS
-</SECTION>
-
-<SECTION>
<FILE>gda-report-client</FILE>
GdaReportClientPrivate
<TITLE>GdaReportClient</TITLE>
@@ -736,6 +736,20 @@
</SECTION>
<SECTION>
+<FILE>gda-report-datasource</FILE>
+GdaReportDatasourcePrivate
+<TITLE>GdaReportDatasource</TITLE>
+gda_report_datasource_new
+<SUBSECTION Standard>
+GDA_REPORT_DATASOURCE
+GDA_IS_REPORT_DATASOURCE
+GDA_TYPE_REPORT_DATASOURCE
+gda_report_datasource_get_type
+GDA_REPORT_DATASOURCE_CLASS
+GDA_IS_REPORT_DATASOURCE_CLASS
+</SECTION>
+
+<SECTION>
<FILE>gda-report-document</FILE>
GdaReportDocumentPrivate
<TITLE>GdaReportDocument</TITLE>
@@ -752,22 +766,21 @@
</SECTION>
<SECTION>
-<FILE>gda-report-datasource</FILE>
-GdaReportDatasourcePrivate
-<TITLE>GdaReportDatasource</TITLE>
-gda_report_datasource_new
-<SUBSECTION Standard>
-GDA_REPORT_DATASOURCE
-GDA_IS_REPORT_DATASOURCE
-GDA_TYPE_REPORT_DATASOURCE
-gda_report_datasource_get_type
-GDA_REPORT_DATASOURCE_CLASS
-GDA_IS_REPORT_DATASOURCE_CLASS
+<FILE>libgda</FILE>
+gda_init
+GdaInitFunc
+gda_main_run
+gda_main_quit
</SECTION>
<SECTION>
<FILE>gda-command</FILE>
GdaCommand
+GdaCommandOption
+GDA_COMMAND_OPTION_IGNORE_ERRORS
+GDA_COMMAND_OPTION_STOP_ON_ERRORS
+GDA_COMMAND_OPTION_BAD_OPTION
+GDA_COMMAND_DEFAULT_OPTION
GdaCommandType
gda_command_new
gda_command_free
@@ -775,6 +788,8 @@
gda_command_set_text
gda_command_get_command_type
gda_command_set_command_type
+gda_command_get_options
+gda_command_set_options
</SECTION>
<SECTION>
@@ -858,12 +873,6 @@
</SECTION>
<SECTION>
-<FILE>gda-util</FILE>
-gda_file_load
-gda_file_save
-</SECTION>
-
-<SECTION>
<FILE>gda-row</FILE>
GdaRow
GdaRowAttributes
@@ -930,21 +939,9 @@
</SECTION>
<SECTION>
-<FILE>gda-xql-utils</FILE>
-gda_xql_gensym
-gda_xql_destroy_hash_pair
-gda_xql_dom_to_xml
-gda_xql_dom_to_sql
-gda_xql_new_node
-gda_xql_new_attr
-</SECTION>
-
-<SECTION>
-<FILE>libgda</FILE>
-gda_init
-GdaInitFunc
-gda_main_run
-gda_main_quit
+<FILE>gda-util</FILE>
+gda_file_load
+gda_file_save
</SECTION>
<SECTION>
@@ -1021,6 +1018,16 @@
gda_value_get_tinyint
gda_value_set_tinyint
gda_value_stringify
+</SECTION>
+
+<SECTION>
+<FILE>gda-xql-utils</FILE>
+gda_xql_gensym
+gda_xql_destroy_hash_pair
+gda_xql_dom_to_xml
+gda_xql_dom_to_sql
+gda_xql_new_node
+gda_xql_new_attr
</SECTION>
<SECTION>
Index: doc/C/tmpl/gda-command.sgml
===================================================================
RCS file: /cvs/gnome/libgda/doc/C/tmpl/gda-command.sgml,v
retrieving revision 1.2
diff -u -r1.2 gda-command.sgml
--- doc/C/tmpl/gda-command.sgml 2001/12/22 01:01:10 1.2
+++ doc/C/tmpl/gda-command.sgml 2002/01/18 15:42:42
@@ -2,10 +2,12 @@
gda-command
<!-- ##### SECTION Short_Description ##### -->
+Functions that deals with #GdaCommand.
-
<!-- ##### SECTION Long_Description ##### -->
<para>
+The #GdaCommand structure holds data needed to issue a command to the
+providers.
</para>
@@ -20,15 +22,58 @@
</para>
+<!-- ##### TYPEDEF GdaCommandOption ##### -->
+<para>
+And OR'ed combination of GDA_COMMAND_OPTIONS_* values.
+
+</para>
+
+
+<!-- ##### MACRO GDA_COMMAND_OPTION_IGNORE_ERRORS ##### -->
+<para>
+Instruct the provider to ignore errors in the execution of commands and
+continue processing. Conflicts with #GDA_COMMAND_OPTION_STOP_ON_ERRORS.
+
+</para>
+
+
+
+<!-- ##### MACRO GDA_COMMAND_OPTION_STOP_ON_ERRORS ##### -->
+<para>
+Instruct the provider to stop in case of error when executing commands. The
+provider should add an error to the connection and return NULL. Conflicts
+with #GDA_COMMAND_OPTION_IGNORE_ERRORS.
+
+</para>
+
+
+
+<!-- ##### MACRO GDA_COMMAND_OPTION_BAD_OPTION ##### -->
+<para>
+Returned value for #gda_command_get_option if the argument is NULL.
+
+</para>
+
+
+
+<!-- ##### MACRO GDA_COMMAND_DEFAULT_OPTION ##### -->
+<para>
+
+</para>
+
+
+
<!-- ##### ENUM GdaCommandType ##### -->
<para>
</para>
- GDA_COMMAND_TYPE_SQL:
+ GDA_COMMAND_TYPE_SQL: the text of the command is composed of zero or more SQL
+sentences.
@GDA_COMMAND_TYPE_XML:
@GDA_COMMAND_TYPE_PROCEDURE:
- GDA_COMMAND_TYPE_TABLE:
+ GDA_COMMAND_TYPE_TABLE: the text of the command is composed of zero or more
+table names.
@GDA_COMMAND_TYPE_INVALID:
<!-- ##### FUNCTION gda_command_new ##### -->
@@ -38,6 +83,7 @@
@text:
@type:
+ option:
@Returns:
@@ -83,5 +129,23 @@
@cmd:
@type:
+
+
+<!-- ##### FUNCTION gda_command_get_options ##### -->
+<para>
+
+</para>
+
+ cmd:
+ Returns:
+
+
+<!-- ##### FUNCTION gda_command_set_options ##### -->
+<para>
+
+</para>
+
+ cmd:
+ option:
Index: idl/ChangeLog
===================================================================
RCS file: /cvs/gnome/libgda/idl/ChangeLog,v
retrieving revision 1.23
diff -u -r1.23 ChangeLog
--- idl/ChangeLog 2002/01/14 23:13:29 1.23
+++ idl/ChangeLog 2002/01/18 15:42:42
@@ -1,3 +1,7 @@
+2002-01-17 Gonzalo Paniagua Javier <gonzalo gnome-db org>
+
+ * GNOME_Database.idl: added CommandOption.
+
2002-01-14 Rodrigo Moya <rodrigo gnome-db org>
* GNOME_Database.idl: added ValueList type
Index: idl/GNOME_Database.idl
===================================================================
RCS file: /cvs/gnome/libgda/idl/GNOME_Database.idl,v
retrieving revision 1.17
diff -u -r1.17 GNOME_Database.idl
--- idl/GNOME_Database.idl 2002/01/14 23:13:29 1.17
+++ idl/GNOME_Database.idl 2002/01/18 15:42:43
@@ -118,6 +118,13 @@
* The Command struct contains information about a
* command to be executed on the server
*/
+ typedef long CommandOption;
+ const CommandOption IGNORE_ERRORS = 1;
+ const CommandOption STOP_ON_ERRORS = 1 << 1;
+ const CommandOption BAD_OPTION = 1 << 2;
+ const CommandOption DEFAULT_OPTION = 1 << 1;
+
+
enum CommandType {
COMMAND_TYPE_SQL,
COMMAND_TYPE_XML,
@@ -129,6 +136,7 @@
struct Command {
string text;
CommandType type;
+ CommandOption option;
};
/*
Index: libgda/ChangeLog
===================================================================
RCS file: /cvs/gnome/libgda/libgda/ChangeLog,v
retrieving revision 1.79
diff -u -r1.79 ChangeLog
--- libgda/ChangeLog 2002/01/15 20:12:52 1.79
+++ libgda/ChangeLog 2002/01/18 15:42:43
@@ -1,3 +1,8 @@
+2002-01-17 Gonzalo Paniagua Javier <gonzalo gnome-db org>
+
+ * gda-command.[ch]: added new type GdaCommandOption and get/set
+ functions for it. Also added documentation for all the functions.
+
2002-01-15 Gonzalo Paniagua Javier <gonzalo gnome-db org>
* gda-value.c: added documentation. Corrected changed parameter value
Index: libgda/gda-command.c
===================================================================
RCS file: /cvs/gnome/libgda/libgda/gda-command.c,v
retrieving revision 1.3
diff -u -r1.3 gda-command.c
--- libgda/gda-command.c 2002/01/11 16:37:47 1.3
+++ libgda/gda-command.c 2002/01/18 15:42:43
@@ -24,21 +24,40 @@
/**
* gda_command_new
+ * @text: the text of the command.
+ * @type: a #GdaCommandType value.
+ * @option: a #GdaCommandOption value.
+ *
+ * Creates a new #GdaCommand from the parameters that should be freed by
+ * calling #gda_command_free.
+ *
+ * If there are conflicting options, this will set @option to
+ * #GDA_COMMAND_OPTION_DEFAULT.
+ *
+ * Returns: a newly allocated #GdaCommand.
*/
GdaCommand *
-gda_command_new (const gchar *text, GdaCommandType type)
+gda_command_new (const gchar *text, GdaCommandType type,
+ GdaCommandOption option)
{
GdaCommand *cmd;
cmd = GNOME_Database_Command__alloc ();
gda_command_set_text (cmd, text);
gda_command_set_command_type (cmd, type);
+ cmd->option = GDA_COMMAND_OPTION_BAD_OPTION;
+ gda_command_set_options (cmd, option);
+ if (cmd->option == GDA_COMMAND_OPTION_BAD_OPTION)
+ cmd->option = GDA_COMMAND_DEFAULT_OPTION;
return cmd;
}
/**
* gda_command_free
+ * @cmd: a #GdaCommand.
+ *
+ * Frees the resources allocated by #gda_command_new.
*/
void
gda_command_free (GdaCommand *cmd)
@@ -49,6 +68,11 @@
/**
* gda_command_get_text
+ * @cmd: a #GdaCommand.
+ *
+ * Get the command text held by @cmd.
+ *
+ * Returns: the command string of @cmd.
*/
const gchar *
gda_command_get_text (GdaCommand *cmd)
@@ -59,6 +83,10 @@
/**
* gda_command_set_text
+ * @cmd: a #GdaCommand
+ * @text: the command text.
+ *
+ * Sets the command text of @cmd.
*/
void
gda_command_set_text (GdaCommand *cmd, const gchar *text)
@@ -76,6 +104,11 @@
/**
* gda_command_get_command_type
+ * @cmd: a #GdaCommand.
+ *
+ * Gets the command type of @cmd.
+ *
+ * Returns: the command type of @cmd.
*/
GdaCommandType
gda_command_get_command_type (GdaCommand *cmd)
@@ -86,6 +119,10 @@
/**
* gda_command_set_command_type
+ * @cmd: a #GdaCommand
+ * @type: the command type.
+ *
+ * Sets the command type of @cmd.
*/
void
gda_command_set_command_type (GdaCommand *cmd, GdaCommandType type)
@@ -93,3 +130,43 @@
g_return_if_fail (cmd != NULL);
cmd->type = type;
}
+
+/**
+ * gda_command_get_options
+ * @cmd: a #GdaCommand.
+ *
+ * Gets the command option of @cmd.
+ *
+ * Returns: the command option of @cmd.
+ */
+GdaCommandOption
+gda_command_get_options (GdaCommand *cmd)
+{
+ g_return_val_if_fail (cmd != NULL, GDA_COMMAND_OPTION_BAD_OPTION);
+ return cmd->option;
+}
+
+/**
+ * gda_command_set_options
+ * @cmd: a #GdaCommand
+ * @option: the command option.
+ *
+ * Sets the command option of @cmd. If there conflicting options, it will just
+ * leave the value as before.
+ */
+void
+gda_command_set_options (GdaCommand *cmd, GdaCommandOption option)
+{
+ GdaCommandOption err_mask;
+
+ g_return_if_fail (cmd != NULL);
+
+ err_mask = GDA_COMMAND_OPTION_IGNORE_ERRORS |
+ GDA_COMMAND_OPTION_STOP_ON_ERRORS;
+
+ if ((option & err_mask) == err_mask)
+ return; // Conflicting options!
+
+ cmd->option = option;
+}
+
Index: libgda/gda-command.h
===================================================================
RCS file: /cvs/gnome/libgda/libgda/gda-command.h,v
retrieving revision 1.4
diff -u -r1.4 gda-command.h
--- libgda/gda-command.h 2002/01/11 16:37:47 1.4
+++ libgda/gda-command.h 2002/01/18 15:42:43
@@ -29,6 +29,14 @@
G_BEGIN_DECLS
typedef GNOME_Database_Command GdaCommand;
+
+typedef GNOME_Database_CommandOption GdaCommandOption;
+#define GDA_COMMAND_OPTION_IGNORE_ERRORS GNOME_Database_IGNORE_ERRORS
+#define GDA_COMMAND_OPTION_STOP_ON_ERRORS GNOME_Database_STOP_ON_ERRORS
+#define GDA_COMMAND_OPTION_BAD_OPTION GNOME_Database_BAD_OPTION
+#define GDA_COMMAND_DEFAULT_OPTION GNOME_Database_DEFAULT_OPTION
+
+
typedef enum {
GDA_COMMAND_TYPE_SQL = GNOME_Database_COMMAND_TYPE_SQL,
GDA_COMMAND_TYPE_XML = GNOME_Database_COMMAND_TYPE_XML,
@@ -37,13 +45,16 @@
GDA_COMMAND_TYPE_INVALID = GNOME_Database_COMMAND_TYPE_INVALID
} GdaCommandType;
-GdaCommand *gda_command_new (const gchar *text, GdaCommandType type);
+GdaCommand *gda_command_new (const gchar *text, GdaCommandType type,
+ GdaCommandOption option);
void gda_command_free (GdaCommand *cmd);
const gchar *gda_command_get_text (GdaCommand *cmd);
void gda_command_set_text (GdaCommand *cmd, const gchar *text);
GdaCommandType gda_command_get_command_type (GdaCommand *cmd);
void gda_command_set_command_type (GdaCommand *cmd, GdaCommandType type);
+GdaCommandOption gda_command_get_options (GdaCommand *cmd);
+void gda_command_set_options (GdaCommand *cmd, GdaCommandOption option);
G_END_DECLS
Index: providers/postgres/ChangeLog
===================================================================
RCS file: /cvs/gnome/libgda/providers/postgres/ChangeLog,v
retrieving revision 1.12
diff -u -r1.12 ChangeLog
--- providers/postgres/ChangeLog 2002/01/15 01:53:25 1.12
+++ providers/postgres/ChangeLog 2002/01/18 15:42:44
@@ -1,3 +1,7 @@
+2002-01-17 Gonzalo Paniagua Javier <gonzalo gnome-db org>
+
+ * gda-postgres-provider.c: added support for GdaCommandOption.
+
2002-01-15 Gonzalo Paniagua Javier <gonzalo gnome-db org>
* gda-postgres-provider.c:
Index: providers/postgres/gda-postgres-provider.c
===================================================================
RCS file: /cvs/gnome/libgda/providers/postgres/gda-postgres-provider.c,v
retrieving revision 1.7
diff -u -r1.7 gda-postgres-provider.c
--- providers/postgres/gda-postgres-provider.c 2002/01/15 01:53:25 1.7
+++ providers/postgres/gda-postgres-provider.c 2002/01/18 15:42:44
@@ -305,7 +305,8 @@
}
static GList *
-process_sql_commands (GList *reclist, GdaServerConnection *cnc, const gchar *sql)
+process_sql_commands (GList *reclist, GdaServerConnection *cnc,
+ const gchar *sql, GdaCommandOption option)
{
GdaPostgresConnectionPrivate *priv_data;
PGconn *pconn;
@@ -339,7 +340,8 @@
}
status = PQresultStatus(pg_res);
- if (status == PGRES_TUPLES_OK ||
+ if (option & GDA_COMMAND_OPTION_IGNORE_ERRORS ||
+ status == PGRES_TUPLES_OK ||
status == PGRES_COMMAND_OK) {
recset = gda_postgres_recordset_new (cnc, pg_res);
if (GDA_IS_SERVER_RECORDSET (recset))
@@ -372,18 +374,21 @@
GList *reclist = NULL;
gchar *str;
GdaPostgresProvider *pg_prv = (GdaPostgresProvider *) provider;
+ GdaCommandOption option;
g_return_val_if_fail (GDA_IS_POSTGRES_PROVIDER (pg_prv), NULL);
g_return_val_if_fail (GDA_IS_SERVER_CONNECTION (cnc), NULL);
g_return_val_if_fail (cmd != NULL, NULL);
+ option = gda_command_get_options (cmd);
switch (gda_command_get_command_type (cmd)) {
case GDA_COMMAND_TYPE_SQL :
- reclist = process_sql_commands (reclist, cnc, gda_command_get_text (cmd));
+ reclist = process_sql_commands (reclist, cnc, gda_command_get_text (cmd),
+ option);
break;
case GDA_COMMAND_TYPE_TABLE :
str = g_strdup_printf ("SELECT * FROM %s", gda_command_get_text (cmd));
- reclist = process_sql_commands (reclist, cnc, str);
+ reclist = process_sql_commands (reclist, cnc, str, option);
g_free (str);
break;
default:
@@ -489,7 +494,8 @@
g_return_val_if_fail (GDA_IS_SERVER_CONNECTION (cnc), NULL);
reclist = process_sql_commands (NULL, cnc,
- "SELECT proname FROM pg_proc ORDER BY proname");
+ "SELECT proname FROM pg_proc ORDER BY proname",
+ GDA_COMMAND_OPTION_STOP_ON_ERRORS);
if (!reclist)
return NULL;
@@ -510,7 +516,8 @@
reclist = process_sql_commands (NULL, cnc,
"SELECT relname FROM pg_class WHERE relkind = 'r' AND "
- "relname !~ '^pg_' ORDER BY relname");
+ "relname !~ '^pg_' ORDER BY relname",
+ GDA_COMMAND_OPTION_STOP_ON_ERRORS);
if (!reclist)
return NULL;
@@ -577,7 +584,8 @@
reclist = process_sql_commands (NULL, cnc,
"SELECT relname FROM pg_class WHERE relkind = 'v' AND "
- "relname !~ '^pg_' ORDER BY relname");
+ "relname !~ '^pg_' ORDER BY relname",
+ GDA_COMMAND_OPTION_STOP_ON_ERRORS);
if (!reclist)
return NULL;
Index: testing/ChangeLog
===================================================================
RCS file: /cvs/gnome/libgda/testing/ChangeLog,v
retrieving revision 1.26
diff -u -r1.26 ChangeLog
--- testing/ChangeLog 2002/01/15 20:23:54 1.26
+++ testing/ChangeLog 2002/01/18 15:42:45
@@ -1,3 +1,7 @@
+2002-01-17 Gonzalo Paniagua Javier <gonzalo gnome-db org>
+
+ * postgres-test.c: added support GdaCommandOption.
+
2002-01-15 Gonzalo Paniagua Javier <gonzalo gnome-db org>
* models.h: added declaration of display_recordset_data().
Index: testing/postgres-test.c
===================================================================
RCS file: /cvs/gnome/libgda/testing/postgres-test.c,v
retrieving revision 1.3
diff -u -r1.3 postgres-test.c
--- testing/postgres-test.c 2002/01/14 23:40:15 1.3
+++ testing/postgres-test.c 2002/01/18 15:42:45
@@ -22,6 +22,9 @@
#include "postgres-test.h"
+#define IGNORE_ERR GDA_COMMAND_OPTION_IGNORE_ERRORS
+#define STOP_ON_ERR GDA_COMMAND_OPTION_STOP_ON_ERRORS
+
static gboolean
create_table (GdaConnection *cnc)
{
@@ -46,9 +49,10 @@
"timestamp_value timestamp, "
"null_value char(1) "
")",
- GDA_COMMAND_TYPE_SQL);
+ GDA_COMMAND_TYPE_SQL, STOP_ON_ERR);
- list = gda_connection_execute_command (cnc, create_command, NULL);
+ list = gda_connection_execute_command (cnc, create_command,
+ NULL);
retval = list == NULL ? FALSE : TRUE;
g_list_foreach (list, (GFunc) g_object_unref, NULL);
g_list_free (list);
@@ -65,7 +69,7 @@
GList *list;
drop_command = gda_command_new ( "drop table gda_postgres_test",
- GDA_COMMAND_TYPE_SQL);
+ GDA_COMMAND_TYPE_SQL, IGNORE_ERR);
list = gda_connection_execute_command (cnc, drop_command, NULL);
retval = list == NULL ? FALSE : TRUE;
@@ -113,7 +117,7 @@
"'2004-02-29 14:00:11.31', "
"'(1,0)' "
")",
- GDA_COMMAND_TYPE_SQL);
+ GDA_COMMAND_TYPE_SQL, STOP_ON_ERR);
list = gda_connection_execute_command (cnc, insert_command, NULL);
gda_command_free (insert_command);
@@ -128,9 +132,10 @@
GList *list;
select_command = gda_command_new ( "select * from gda_postgres_test",
- GDA_COMMAND_TYPE_SQL);
+ GDA_COMMAND_TYPE_SQL, STOP_ON_ERR);
- list = gda_connection_execute_command (cnc, select_command, NULL);
+ list = gda_connection_execute_command (cnc, select_command,
+ NULL);
gda_command_free (select_command);
return list;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]