<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"><channel><category>pcsoft.us.windev</category><copyright>Copyright 2026, PC SOFT</copyright><lastBuildDate>10 Mar 2020 15:40:57 Z</lastBuildDate><pubDate>5 Mar 2020 02:57:50 Z</pubDate><description>I spent a whole day trying to find out a solution for this:&#13;
Inside a string variable I have many insert SQL command separated by comma. It´s generated on-the-fly using data received using a Webservice. It´s a bulk load insert.&#13;
Some errors can occur in this process like the I faced out today. A special caracter. It broked one of 400 SQL commands inside of my "SQL Buffer Commands". &#13;
&#13;
My code is :&#13;
&#13;
Procedure InsertSQLCommands(insCMD)&#13;
&#13;
SQLTransaction(sqlStart,MyCon)&#13;
	WHEN EXCEPTION IN&#13;
&#13;
		IF HExecuteSQLQuery(dsExecDB,MyCon,hQueryWithoutCorrection,insCMD) THEN&#13;
		  IF ErrorOccurred THEN&#13;
		  	Info(ErrorInfo(errFullDetails))	&#13;
		  END&#13;
		&#13;
	  	  SQLTransaction(sqlCommit,MyCon)&#13;
		  RESULT True&#13;
		ELSE&#13;
		  gLog.AddMessage("Falha Inserindo BulkLoad de Publicacoes", "ERRO")&#13;
		  SQLTransaction(sqlRollBack,MyCon)&#13;
		  fSaveText(".\inssql_Erro_" + SysDateTime() + ".sql",insCMD)&#13;
		  RESULT False&#13;
		END&#13;
	DO&#13;
	    gLog.AddMessage("Falha Inserindo BulkLoad de Publicacoes", "Excecao")&#13;
		SQLTransaction(sqlRollBack,MyCon)&#13;
  	    fSaveText(".\inssql_Exc_" + SysDateTime() + ".sql",insCMD)		&#13;
		RESULT False&#13;
	END&#13;
&#13;
Questions:&#13;
Why HExecuteSQLQuery doesnt´t return a false value when an error occurs?&#13;
Transactions doesn´t work?&#13;
Windev is good enougth to work with just and SQL commmand at a time ?&#13;
&#13;
Does some one can give some light about it?</description><ttl>30</ttl><generator>WEBDEV</generator><language>en_US</language><link>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/67678-many-sql-commands-time-with-hexecutesqlquery/read.awp</link><title>Many SQL Commands at a time with HExecuteSQLQuery</title><managingEditor>moderateur@pcsoft.fr (El moderador)</managingEditor><webMaster>webmaster@pcsoft.fr (El webmaster)</webMaster><item><author>marco.a.machado</author><category>pcsoft.us.windev</category><comments>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/67678-many-sql-commands-time-with-hexecutesqlquery-67684/read.awp</comments><pubDate>10 Mar 2020 15:40:57 Z</pubDate><description>Hi Sebastian&#13;
&#13;
My effords were for nothing.&#13;
HExecuteSQLQuery just works fine using one SQL command at a time.&#13;
I were using 40…</description><guid isPermaLink="true">https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/67678-many-sql-commands-time-with-hexecutesqlquery-67684/read.awp</guid><link>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/67678-many-sql-commands-time-with-hexecutesqlquery-67684/read.awp</link><source url="https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/67678-many-sql-commands-time-with-hexecutesqlquery/read.awp">Many SQL Commands at a time with HExecuteSQLQuery</source><title>Re: Many SQL Commands at a time with HExecuteSQLQuery</title></item><item><author>Sebastian Arnold</author><category>pcsoft.us.windev</category><comments>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/67678-many-sql-commands-time-with-hexecutesqlquery-67682/read.awp</comments><pubDate>9 Mar 2020 17:43:45 Z</pubDate><description>Hi Marco,&#13;
&#13;
just two ideas. &#13;
&#13;
First, try to use HCancelDeclaration() and HFreeQuery() before your HexecuteSQLQuery()&#13;
&#13;
Secon…</description><guid isPermaLink="true">https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/67678-many-sql-commands-time-with-hexecutesqlquery-67682/read.awp</guid><link>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/67678-many-sql-commands-time-with-hexecutesqlquery-67682/read.awp</link><source url="https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/67678-many-sql-commands-time-with-hexecutesqlquery/read.awp">Many SQL Commands at a time with HExecuteSQLQuery</source><title>Re: Many SQL Commands at a time with HExecuteSQLQuery</title></item></channel></rss>
