Method SqlStatement:asString() Foundation
Returns the final SQL statement as it will be send to the SQL server
METHOD :asString() -> cSqlStatement
A character string of the final SQL statement.
The method <asString()> returns the final SQL statement after the :build() or :bind() method operation took place. Execution of :asString() without having executed :build() or :bind() will result in a runtime error as there is no final SQL statement calculated.
oStmt := DacSqlStatement():fromChar("SELECT * FROM customers WHERE city==::SearchTerm")
oStmt:SearchTerm := "Berlin"
// Prints: SELECT * FROM customers WHERE city='Berlin'
? oStmt:Build():asString()
If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.