close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Update page deleting entire record

Thread began 10/31/2016 11:57 am by tmcbinc99963 | Last modified 11/04/2016 11:29 am by Ray Borduin | 1349 views | 4 replies |

tmcbinc99963

Update page deleting entire record

I have an admin page that updates a products/lube relational table by using foreign keys from a products table and a lube table (using the Manage Relational Tables server behavior).

When I attempt to update the product type checkbox list (from grease to engine oils, for example), it updates the product/lube table primary key to a value of 0, resulting in a 'this record has been removed' message.

The Lube and Product foreign keys update correctly.

The site pages are included and can be viewed live (see PM).

Sign in to reply to this post

Ray BorduinWebAssist

It looks like you haven't defined your prodtype table to have an autonumber column. That is preventing the inserts for the new checked lube types.

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

tmcbinc99963

Locally, auto_increment was added to the prodtype table, and a new search was performed for product number 201. The results still say 'record has been removed', and the record is gone from the prodtype foreign key table (the record is still there in the products table). In addition, the new search won't find any of the first 5 products with primary keys 1-5 for some reason.

When the record is added back in to the prodtype table manually, and a new search is performed for that product, it returns 'no record found'. And, still doesn't find the first five products.

When the Db is replaced with a backup from the remote server, the search works properly, including finding the first 5 products.

Sign in to reply to this post

Ray BorduinWebAssist

You have four INNER JOIN references in your recordset on the results page. That means if there aren't associated records in any of the four associated tables the recordset won't return results.

If you change them to LEFT OUTER JOIN instead then the results page will return results even if the joined tables don't have associated rows. If adding the prodtype manually doesn't fix the problem it means the problem is (also?) with the lubetype, prodsize, or contsize tables.

In your case it was an issue with an old checkbox name reference in the manage relational table server behavior for the prodsize table.

It appears you still have an issue with the autonumber column not being set for either the prodtype or prodsize table.

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

tmcbinc99963

The issue seemed to be adding auto_increment to every associated table. I had corrected every table except the products table. It's working as expected now.

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...