|
 |
asp_databases thread: SQL strings, queries and JOIN !
Message #1 by Paul Bucknell <paul@d...> on Sat, 27 May 2000 21:35:24 +0100
|
|
Help!
I'm trying to display data from two tables contributors and users into one
HTML table to show how
has contributed the data. I don't want to replicate the data so each
contributor is a registered user
in the user database. The contributors table then just lists the userid of
each contributor.
This works well in ACCESS, my database.
When I copy the SQL string into my asp file it bombs big time, why?
I have copied two strings below that I have tried !
SELECT DISTINCTROW contributors.userid, users.email, users.name,
users.quals FROM contributors INNER JOIN users ON contributors.userid =
users.userid;
SELECT [userid], [email], [name], [quals] FROM [contributors Query];
Thank you in advance.
Message #2 by "Velzen, Marvin van" <MVE@e...> on Mon, 29 May 2000 10:29:58 +0200
|
|
SELECT * FROM contributors LEFT JOIN users ON contributors.userid =
users.userid
Try this one, you can then always specify the statement further.
Marvin
-----Original Message-----
From: Paul Bucknell []
Sent: zaterdag 27 mei 2000 22:35
To: ASP Databases
Subject: [asp_databases] SQL strings, queries and JOIN !
Help!
I'm trying to display data from two tables contributors and users into one
HTML table to show how
has contributed the data. I don't want to replicate the data so each
contributor is a registered user
in the user database. The contributors table then just lists the userid of
each contributor.
This works well in ACCESS, my database.
When I copy the SQL string into my asp file it bombs big time, why?
I have copied two strings below that I have tried !
SELECT DISTINCTROW contributors.userid, users.email, users.name,
users.quals FROM contributors INNER JOIN users ON contributors.userid =
users.userid;
SELECT [userid], [email], [name], [quals] FROM [contributors Query];
Thank you in advance.
Message #3 by "Ken Schaefer" <ken.s@a...> on Sun, 28 May 2000 23:11:29 +1000
|
|
>> The error is on line 6
> How do you know? I didn't post any code...
Exactly
How about giving us the error message, and where the error is occuring...
Cheers
Ken
----- Original Message -----
From: "Paul Bucknell"
To: "ASP Databases" <asp_databases@p...>
Sent: Sunday, May 28, 2000 6:35 AM
Subject: [asp_databases] SQL strings, queries and JOIN !
> Help!
>
> I'm trying to display data from two tables contributors and users into one
> HTML table to show how
> has contributed the data. I don't want to replicate the data so each
> contributor is a registered user
> in the user database. The contributors table then just lists the userid of
> each contributor.
>
> This works well in ACCESS, my database.
>
> When I copy the SQL string into my asp file it bombs big time, why?
>
> I have copied two strings below that I have tried !
>
>
>
> SELECT DISTINCTROW contributors.userid, users.email, users.name,
> users.quals FROM contributors INNER JOIN users ON contributors.userid
> users.userid;
>
>
> SELECT [userid], [email], [name], [quals] FROM [contributors Query];
>
>
> Thank you in advance.
>
>
>
>
|
|
 |