I have three tables.
tblVenue
Venue_NUM (Primary Key)
VenueName
tblShow
Show_NUM (Primary Key)
Venue_NUM (Link to tblVenue)
BandName
tblRatings
Ratings_NUM (Primary Key)
Show_NUM (Link to tblShow)
Rating
IP_Address
I am trying to figure out how to write an SQL statement that would show:
tblVenue.VenueName, tblShow.BandName, 0, 4
where 0 is the count of ratings entered by the person at IP address 192.168.1.1 and 4 is the average of all the ratings for tblShow.BandName.
And I cannot write multiple SQL statements, this all has to be inside of one SQL statement. Is it possible?
Thanks
-Al
tblVenue
Venue_NUM (Primary Key)
VenueName
tblShow
Show_NUM (Primary Key)
Venue_NUM (Link to tblVenue)
BandName
tblRatings
Ratings_NUM (Primary Key)
Show_NUM (Link to tblShow)
Rating
IP_Address
I am trying to figure out how to write an SQL statement that would show:
tblVenue.VenueName, tblShow.BandName, 0, 4
where 0 is the count of ratings entered by the person at IP address 192.168.1.1 and 4 is the average of all the ratings for tblShow.BandName.
And I cannot write multiple SQL statements, this all has to be inside of one SQL statement. Is it possible?
Thanks
-Al