Recent content by jolly green

  1. J

    Using SELECT results for INNER JOIN

    The problem has been solved. A user on another forum has provided the solution. The clauses have been reworked and in Access97 aliasing a table requires square brackets and a period. This is alot of hassle all because A97 does not support INTERSECT. SELECT * FROM Card WHERE pk IN ( SELECT pk...
  2. J

    Using SELECT results for INNER JOIN

    I didn't mention it in the first post but the numbers in parenthesis are chosen at runtime by the user. While in my post I used (8,2,4) it could be whatever the user chooses. I think I may just endup doing the INNER JOIN by code. At worst it will be O(n*n) search.
  3. J

    Using SELECT results for INNER JOIN

    Thanks for the suggestion on aliasing the query results. I have tried this SELECT * FROM Card WHERE Card.pk IN ( (SELECT cardFK FROM Card_Tag WHERE tagFK IN (9,6) GROUP BY cardFK HAVING COUNT(cardFK) = 2) AS X INNER JOIN (SELECT cardFK FROM Card_Source WHERE sourceFK IN (8,2,4) GROUP...
  4. J

    Using SELECT results for INNER JOIN

    So you're saying replace the entire statement with just the second SELECT statement? If I delete the first SELECT statement I will not be able to perform a AND query on both tables. On the issue of getting 0 results. The first SELECT refers to join table Card_Tag and queries on [tagFK]. The...
  5. J

    Using SELECT results for INNER JOIN

    Hello. Im using Access 97 and the query is complaining about a "syntax error missing operator". I suspect it has something to do with using two SELECTs for the INNER JOIN. INNER JOIN expects table names but I thought a SELECT returns a table. SELECT * FROM Card WHERE Card.pk IN ( (SELECT...
Back
Top Bottom