On-rev and irev file problem?
bobs at twft.com
Fri Sep 30 14:25:09 EDT 2011
Whoops! Sorry did not see the iRev and on-rev part. Try writing the contents of the variables out to a log file.
On Sep 30, 2011, at 11:12 AM, John Patten wrote:
> Hi All..
> I duplicated a script that is working to send data to on-rev mysql database in another project. The new project keeps throwing up a server connection error.
> I've tried to boil it down to the most basic components to trouble shoot, but I still get errors. I 'have looked for typos over and over but don't see anything. Here is what I have in its most basic form:
> put $_POST["mymessage"] into mymessage
> set itemDel to tab
> put item 1 of mymessage into tTargetPerson
> put item 2 of mymessage into tTargetNorm
> put itemDel into tCurrentItemDel
> set the itemDel to "|"
> put item 1 of tTargetNorm into tNorm_heading
> put item 2 of tTargetNorm into tNorm_topic
> set the itemDel to tab
> put item 3 of mymessage into tEventDescription
> put "localhost" into tDatabaseAddress
> put "xxxxxx_norms" into tDatabaseName
> put "xxxxxx_normuser" into tDatabaseuser
> put "xxxxxxx" into tDatabasePassword
> put tDatabaseAddress & " " & tDatabaseName & " " & tDatabaseuser & " " & tDatabasePassword into tResult
> --put revOpenDatabase("mysql", tDatabaseAddress, tDatabaseName, tDatabaseuser, tDatabasePassword) into tResult
> --if tResult is not a number then
> --put "Error: could not connect to database " & tResult
> --put "target_person, norm_heading, norm_topic, description" into tFields
> --put "INSERT INTO norms " & "(" & tFields & ") & VALUES (:1, :2, :3, :4)" into tSQL
> answer tResult
> --revExecuteSQL tResult, tSQL, "tTargetPerson", "tNorm_heading", "tNorm_topic", "tEventDescription"
> I'm at the point now I'm just trying to see what the connection contents is in tResult, and it still throws up the server error???
> Any advice?
> Thank you!
> John Patten
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
More information about the Use-livecode