Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Recordset '.update' - can the SQL be written to screen?

Status
Not open for further replies.

zooter96

IS-IT--Management
Jul 7, 2005
1
CA
HI, I keep getting a 'syntax error in UPDATE statement' error when calling my objRS.update method. Is there a way the SQL for the update statement can be written to the screen so it may be inspected.

 
You can do this, eg:-

<%
SQL = &quot;update myTable set myName='Martin'&quot;
Response.Write( &quot;The SQL is: &quot; &SQL& &quot;<BR>&quot; )
set myRS = myConn.Execute( SQL )
%>

Or similarly:-

<% SQL = &quot;update myTable set myName='Martin'&quot; %>
The SQL is: <%=SQL%><BR>
<% set myRS = myConn.Execute( SQL ) %>

Hope I understood the question, Martin Davey.
 
I think that there is a recordset property that allows you to getSQLtext I am not positive of this since I no longer have VID to check it with. I know there is a setSQLtext at least with the DTC's in Interdev.

I don't know if this will be any help......
Crystal
crystalized_s@yahoo.com

--------------------------------------------------

Experience is one thing you can't get for nothing.

-Oscar Wilde

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top