close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Modifying Wizard search parameters and detail page links for products that have more than one product type

Thread began 11/21/2016 12:37 pm by tmcbinc99963 | Last modified 11/22/2016 2:50 pm by Ray Borduin | 1630 views | 8 replies |

tmcbinc99963

Modifying Wizard search parameters and detail page links for products that have more than one product type

I've created a DataAssist product search, to search by product number and product type. It works as it should if each product has a unique product type. However, some products have multiple product types. For example, a search for product 252 should have a result of 252 Torque and 252 Tractor.

A separate Db table using foreign keys for both product and product type works properly on a dynamic tab panel in the site, but not on the DataAssist results and Detail pages:

A search for '252' returns only 252 Torque, rather than 252 Torque and 252 Tractor.
A search for 'Torque' lists 252 Torque; a search for 'Tractor' lists 252 Tractor, which is correct.
When clicking the 252 Torque detail link it goes to 252 Torque. When clicking the 252 Tractor detail link it goes to 252 Torque, rather than 252 Tractor.

The recordsets all have INNER JOINs to combine the appropriate tables in addition to the separate product and product type table mentioned above.

Tried reconfiguring the search and also using AND in the Wizard, but still doesn't work properly.

On a related note, the tab panel that uses the FK table also returns 252 Torque regardless of which product is chosen.

Files attached.

Sign in to reply to this post

Ray BorduinWebAssist

I added a group_concat() to your SQL statement to return multiple categories when applicable.

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

tmcbinc99963

252 Torque and 252 Tractor should appear in the results as two different listings, each with their own unique link to the detail page.

In the tab panel, clicking the 252 link (under the Torque tab) should show the 252 Torque product on the detail page (works properly). Clicking the 252 Tractor link (under the Tractor tab) should show the 252 Tractor product on the detail page (still shows 252 Torque).

(252 is just one example. There are four other products that have multiple product types; possibly more upcoming)

Sign in to reply to this post

Ray BorduinWebAssist

What are the two product ID's for the 252 torque and 252 tractor products? They will need different IDs to have separate links to the detail page.

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

tmcbinc99963

Product number 252 has an ID of 26 in the 'prod' Db. This ID is used as a foreign key in the 'prodtype' table (column ProdIDType).

The product types originate in the 'lubetype' table as LubeTypeID 4 (torque) and 9 (tractor). These are used as foreign keys in the 'prodtype' table (column LubeID).

The primary key in the 'prodtype' table (column ProdTypeID) for each is 29 and 30

I've tried using the 'prodtype' table, both as a data source in the WADAProd recordset and in updating the Wizard parameters. Neither provided the desired result.

Sign in to reply to this post

Ray BorduinWebAssist

Your SQL statement has GROUP BY ProductID. That will only show one row for each unique product ID. If you change it to GROUP BY ProductID, LubeTypeID, that will show unique rows when either field is unique.

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

tmcbinc99963

The results now show a separate result for each product, which is correct.

The pencil link to the detail page still goes to 252 Torque when 252 Tractor is clicked.

Tried adding ProdIDType to SQL 'GROUP'; plus changing parameter to other Db columns - ProdIDType, LubeID, LubeTypeID.

It shows the expected number in the URL, but returns 'record has been removed'.

Sign in to reply to this post

Ray BorduinWebAssist

You would have to pass both the product ID and lube type ID to the other page in order for it to know which version to display.

I've made the necessary changes so you can see what I mean.

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

tmcbinc99963

Works perfectly. Thanks Ray.

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