Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Community » Newbie corner » Getting the SQL statement without execute it
Getting the SQL statement without execute it [message #50661] Fri, 30 November 2018 12:49
Giorgio is currently offline  Giorgio
Messages: 218
Registered: August 2015
Experienced Member
Hi there,
is there a way to getting the SQL statement upp is going to issue, without actually execute it?

For example the following code will produce (in PostgreSQL) the SQL statement "insert into PERSONS(NAME, SURNAME) values ('John', 'Doe')" and will execute the query:

try {
      SQL & Insert(PERSONS)
            (NAME, "John")
            (SURNAME, "Doe");
} catch(SqlExc) {
      ErrorOK(t_("Failed adding data to the database due to the following error: ") + SQL.GetLastError());
}


What I would like to have is a way to have the statement "insert into PERSONS(NAME, SURNAME) values ('John', 'Doe')" in a string variable, without actually executing it (so I will not find a new record in the db); is there a way to achieve this?

Thanks,
gio


Previous Topic: TopWindow Run on Background
Next Topic: Non-modal close button?
Goto Forum:
  


Current Time: Thu Apr 25 10:52:54 CEST 2024

Total time taken to generate the page: 0.03057 seconds