[x]
Posted via EE Mobile

Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again.

Question
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

5.4

Getting single record from database when multiple records exist

Asked by swordfishsoup in Active Server Pages (ASP), SQL Query Syntax, Adobe Dreamweaver

Tags: single, record, access, multiple, database

Hi
I have an asp vb site created in DW8 wih an access database, for an online store.

I need some guidence as to the following issue....

I am making a list page with a thumbnail of the products - product name and price, using a repating horizontal region-  and a 'more' button for further info (detail page).

My cunundrum(other than being able to spell conundrum??) is:

Some products have different sizes and colours and prices (depending on size) . The recordset I have  brings up all the entries - so for 'Wizard teddy bear' I just want one item on the list page but as it has three prices - for smal medium and large - my recordset is giving me three results - hence I have teddies galore!

Does that make any sense? There isn't an error message as such I just need to be pointed in the right direction to say something in asp vb for: (english translation)....
# Select all records from the database where category is bla bla  and age group is bla and gender is (boys and girls toys) - but just give me the name and details once and the lowest price so I can add a 'From' £6.99 If there are multiple prices. or the price if there is only one.

Be great to have pointer in the right direction for this. Please let me know I f I need to post any of the specific code for this. The current select statement is:

<%
Dim RsProdsGen
Dim RsProdsGen_cmd
Dim RsProdsGen_numRows

Set RsProdsGen_cmd = Server.CreateObject ("ADODB.Command")
RsProdsGen_cmd.ActiveConnection = MM_MagicalRooms_STRING
RsProdsGen_cmd.CommandText = "SELECT tblProducts.*, tblPrice.*, tblImages.Image, tblProdCat.*, tblSubCat.* FROM (tblTheme RIGHT JOIN (tblSTheme RIGHT JOIN (tblSizeGroup RIGHT JOIN (tblSubCat RIGHT JOIN (tblProdCat RIGHT JOIN (((tblProducts LEFT JOIN tblImages ON tblProducts.ProdID = tblImages.ProdID) LEFT JOIN tblPrice ON tblProducts.ProdID = tblPrice.PriceProdID) LEFT JOIN tblCatList ON tblProducts.ProdID = tblCatList.CatListProdID) ON tblProdCat.CatID = tblCatList.CatListCatID) ON tblSubCat.SubID = tblCatList.CatListSubCatID) ON tblSizeGroup.SizeGroupID = tblPrice.PriceSizeID) ON tblSTheme.SThemeID = tblProducts.ProdSThemeID) ON tblTheme.ThemeID = tblProducts.ProdThemeID) LEFT JOIN (tblAvailColours RIGHT JOIN tblProdColours ON tblAvailColours.AvailColourID = tblProdColours.ProdAvailColour) ON tblProducts.ProdID = tblProdColours.ProdProdID WHERE CatListCatID = ? AND tblImages.ProdID = tblProducts.ProdID AND Featured = True AND ProdGender = ? AND ProdAgeFrom >= ? AND ProdAgeTo <= ? ORDER BY tblProducts.ProdID"
RsProdsGen_cmd.Prepared = true
RsProdsGen_cmd.Parameters.Append RsProdsGen_cmd.CreateParameter("param1", 5, 1, -1, RsProdsGen__MMColParam) ' adDouble
RsProdsGen_cmd.Parameters.Append RsProdsGen_cmd.CreateParameter("param2", 200, 1, 255, RsProdsGen__MMColParam3) ' adVarChar
RsProdsGen_cmd.Parameters.Append RsProdsGen_cmd.CreateParameter("param3", 5, 1, -1, RsProdsGen__MMColParam4) ' adDouble
RsProdsGen_cmd.Parameters.Append RsProdsGen_cmd.CreateParameter("param4", 5, 1, -1, RsProdsGen__MMColParam5) ' adDouble

Set RsProdsGen = RsProdsGen_cmd.Execute
RsProdsGen_numRows = 0
%>

Thanks

Dave
[+][-]10/30/07 11:58 AM, ID: 20179971Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10/30/07 11:59 AM, ID: 20179994Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]10/30/07 12:02 PM, ID: 20180019Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]10/30/07 12:25 PM, ID: 20180273Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10/30/07 12:38 PM, ID: 20180420Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]10/31/07 01:27 AM, ID: 20183394Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]10/31/07 03:08 AM, ID: 20183765Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10/31/07 03:38 AM, ID: 20183944Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]10/31/07 03:56 AM, ID: 20184052Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]10/31/07 04:38 AM, ID: 20184286Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]10/31/07 10:15 AM, ID: 20187289Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/02/07 01:49 AM, ID: 20198932Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]11/02/07 02:28 AM, ID: 20199059Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/02/07 06:30 AM, ID: 20200599Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/02/07 01:45 PM, ID: 20204407Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]11/04/07 03:49 AM, ID: 20210188Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/06/07 01:22 AM, ID: 20222410Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]11/06/07 02:17 AM, ID: 20222667Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/06/07 02:28 AM, ID: 20222701Accepted Solution

View this solution now by starting your 30-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

About this solution

Zones: Active Server Pages (ASP), SQL Query Syntax, Adobe Dreamweaver
Tags: single, record, access, multiple, database
Sign Up Now!
Solution Provided By: Rouchie
Participating Experts: 4
Solution Grade: A
 
[+][-]11/06/07 02:32 AM, ID: 20222721Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]11/06/07 03:34 AM, ID: 20222910Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]11/06/07 03:47 AM, ID: 20222965Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/06/07 04:25 AM, ID: 20223183Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
 
Loading Advertisement...
20091021-EE-VQP-81 / EE_QW_2_20070628