Copy link to clipboard
Copied
HI,
I have 2 sql tables 'activity' and 'rating' with a primary key of 'ratingID'. I've created a dynamic data table on page in which I want to display a column for 'rating_descrip' gathered from the sql 'rating table'. On the page table I've placed {rsActivity.rating_descrip} in a column. I've attached my 'test' page from the rsActivity which shows my 3 matching items culled from masterDB, but each shows all 4 rating descriptions (adult, child,family, teen), when each item has only one rating_descrip that matches its ratingID.
How do I enter a WHERE command or Variable to get just the matching rating_descrip to show? Also attched my screen of advanced recordset.
Copy link to clipboard
Copied
I don't understand. You mention two tables but your select statement only has the rating table. Did you mean to include items from activity also? If so, you need to add that and join the tables.
Copy link to clipboard
Copied
HI,
The activity table is also selected. Everything in SELECT is from the 'activity' table, except the rating.rating_descrip -----
SELECT activityname, Type, Region, image, activityID, Price, activity.ratingID, rating.rating_descrip
I'm not sure what you by ' join' them? I know that is what I need to do to get it to recognize the rating_descrip for a particular activty. I've tried alot of different input into the recordset with no luck. I get all the rating_descrip that are in the rating table.
****** I just got it! I went back to the tutorial
and found the 'join' command. I adapted it to my document and it now displays the correct records with the rating_descrip. Unfortunately, a lot of this is trial an error for me now. I hope it sticks. But its also nice to know I have you guys out there to answer my questions. Thanks,
Copy link to clipboard
Copied
Marking this thread as assumed answered.
Get ready! An upgraded Adobe Community experience is coming in January.
Learn more