Hi Everyone,

Happy New Year a week late! :)

I am trying to get more serious with my programming, I feel fairly confident in my basic abilities except for one... Error checking. That's what I'm trying to get figured out :)

I have a script, that I am using to connect to my database, read, insert, delete or edit the records in there.

most of the time the script works perfectly, but on the occassion it doesn't like when jupiters third moon aligns with uranus, I want the user to be notified to take their head out of their ass... :)

What I have tried is this:

$querytest = "INSERT INTO current VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?)";
if ($stmt = mysqli_prepare($link, $querytest)) {


mysqli_stmt_bind_param($stmt, 'ssssssssss', $FName, $LName, $Add1, $Add2, $City, $State, $Zip, $XCode, $Record, $Reason);
        //Add the record
        mysqli_stmt_execute($stmt);
        printf("Error: %d.\n", mysqli_stmt_errno($stmt));
        printf("%d Row Inserted.\n", mysqli_stmt_affected_rows($stmt));
        

}

//Close the statement
mysqli_stmt_close($stmt);


that was pulled off of the php.net site (For the most part) and adapted slightly to meet my needs, and obviously I edited too much of it :)

If anyone has any ideas I would appreciate it. Even RTFM as long as $M is defined :)



--

Jason Pruim
Raoset Inc.
Technology Manager
MQC Specialist
3251 132nd ave
Holland, MI, 49424
www.raoset.com
[EMAIL PROTECTED]

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to