close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Multiple update records not updating any records.

Thread began 6/27/2016 10:48 am by Kumel | Last modified 6/27/2016 12:47 pm by Ray Borduin | 1467 views | 7 replies |

Kumel

Multiple update records not updating any records.

I have attached current DB table RestaurantTimings

Also attached the page of updating multiple records. screenshots of update record also attached. don't know whats wrong.

The page is retrieving old data properly. i have an multiple insert record behaviour made properly. but update ain't working. i don't know where i have gone wrong!.

Sign in to reply to this post

Ray BorduinWebAssist

Your column names "Start" and "End" are both reserved words in mySQL that shouldn't be used as column names. That may be what is causing this issue.

https://dev.mysql.com/doc/refman/5.5/en/keywords.html

Sign in to reply to this post
Did this help? Tips are appreciated...

Kumel

i changed it to starttime & endtime yet same results. Not updating results

Sign in to reply to this post

Ray BorduinWebAssist

I'd need ftp access and steps to reproduce in order to debug it myself. I'd start by adding code below line 91 like:

echo($WA_Sql);
die();

and see what the update statement looks like... then try to run it in phpMyAdmin directly and see if it generates an error.

Sign in to reply to this post
Did this help? Tips are appreciated...

Kumel

i got following error:

UPDATE `RestaurantTimings` SET `DayID` = 1, `RestaurantID` = 1, `Starttime` = '09:00:00', `Endtime` = '21:30:00', `Closed` = '' WHERE `RestaurantTimingID`='
Notice: Undefined index: RestaurantTimingID in /Applications/XAMPP/xamppfiles/htdocs/food/admin/edit-timings.php on line 171

Btw RestaurantTimingID are unique ID FYI.

Its all on my local server.

line 171:
<input type="hidden" name="WADA_RepeatID_RestaurantTimingID_<?php echo $RepeatSelectionCounter_1; ?>" id="WADA_RepeatID_RestaurantTimingID_<?php echo $RepeatSelectionCounter_1; ?>" value="<?php echo $row_Daylist["RestaurantTimingID"]; ?>" />

Sign in to reply to this post

Kumel

i found the error. its on the value <?php echo $row_Daylist["RestaurantTimingID"]; ?>
its wrong rs linked to. debugging functions really help. are there more as such debugging codes available so next time we can do it ourself?

Sign in to reply to this post

Ray BorduinWebAssist

Debugging is almost always done with echo() and die() statements in places to view the data when a problem occurs. In this case you were having a problem with the update, so I had you add it after the line of code that does the update.

Sign in to reply to this post
Did this help? Tips are appreciated...

Kumel

alright thnks a lot

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...