Skip to main content
Participating Frequently
August 10, 2010
Question

Updating a search record

  • August 10, 2010
  • 2 replies
  • 405 views

I am able to update a record when it's not a search record, when i followed the tutorials in http://www.adobe.com/devnet/dreamweaver/articles/first_dynamic_site_pt2_08.html

However, when I pressed the update button, I get the following error: Incorrect table name"

I checked the update records in the server behaviours option, and it's the correct table name.

This topic has been closed for replies.

2 replies

Jun_yuanAuthor
Participating Frequently
August 11, 2010

The problem is solved, it's got to do with the SQL Code

$updateSQL = sprintf("UPDATE data SET `Date`=%s, `Owner`=%s, `Requester`=%s, `Part Changed`=%s, `Change`=%s WHERE `Change ID`=%s",

GetSQLValueString($_POST['date1'], "date"),
                       GetSQLValueString($_POST['owner1'], "text"),
                       GetSQLValueString($_POST['requester1'], "text"),
                       GetSQLValueString($_POST['partchanged1'], "text"),
                       GetSQLValueString($_POST['changes1'], "text"),
                       GetSQLValueString($_POST['Change_id'], "int"));

My variables are defined with the `` , whereas the table names( data in this example) do not have ''.

Jun_yuanAuthor
Participating Frequently
August 10, 2010

This image shows the update records box:

The update button is after a search page, in the edit link: