show related Access data in Dreamweaver

  • Thread starter redant via AccessMonster.com
  • Start date
R

redant via AccessMonster.com

How do I grab related data in Dreamweaver? I have two tables in Access. I
want to grab a specific title that is of a specific type.

All courses that are of type "Engineering"

I have one Course table with title description etc.

one Type table with all Types which contains a CourseID field that relates to
first table above.

I built a Query in Access it did list only the "Engineering" courses, but in
Dreamweaver the tables do not seem to be linked. I don't seem to have the
ability to grab the name of the course in the first table depending on the
type in the second although they are linked.

Please help.

TY
 
R

redant via AccessMonster.com

This is the code I get from Access:

SELECT Courses.Title, tblType.Type
FROM Courses INNER JOIN tblTy


Does not seem to work in DW
 
J

John Spencer

That has to be only part of the SQL statement. You will need something
like the query below.

Assumptions:
Courses has a field specifying the TypeID
tblType has at least 2 fields. TypeID and Type

I have changed the join type to a left join in order to display all
courses even if they don't have a type specified. And I added an order
by clause to sort the records in Title order

SELECT Courses.Title, tblType.Type
FROM Courses LEFT JOIN tblType
ON Courses.TypeID = tblType.TypeID
Order By Courses.Title

'====================================================
John Spencer
Access MVP 2002-2005, 2007-2009
The Hilltop Institute
University of Maryland Baltimore County
'====================================================
 
R

redant via AccessMonster.com

I did nor get the SQL code to work yet. I selected the Query I created in
Access in the recordset Database Items VIews category and it works. Does
anyone have more info on this?

John said:
That has to be only part of the SQL statement. You will need something
like the query below.

Assumptions:
Courses has a field specifying the TypeID
tblType has at least 2 fields. TypeID and Type

I have changed the join type to a left join in order to display all
courses even if they don't have a type specified. And I added an order
by clause to sort the records in Title order

SELECT Courses.Title, tblType.Type
FROM Courses LEFT JOIN tblType
ON Courses.TypeID = tblType.TypeID
Order By Courses.Title

'====================================================
John Spencer
Access MVP 2002-2005, 2007-2009
The Hilltop Institute
University of Maryland Baltimore County
'====================================================
This is the code I get from Access:
[quoted text clipped - 21 lines]
 
R

redant via AccessMonster.com

Meaning in Dreamweaver in the Advanced recordset dialogue the Access Query
was listed under "Views"
I did nor get the SQL code to work yet. I selected the Query I created in
Access in the recordset Database Items VIews category and it works. Does
anyone have more info on this?
That has to be only part of the SQL statement. You will need something
like the query below.
[quoted text clipped - 24 lines]
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top