On 2008 October 29 (Wed) 03:26:45pm PDT, James Sheridan <[EMAIL PROTECTED]>
wrote:
> Related addendum:
>
> In reading it appears that MySQL treats "," as a CROSS JOIN and implements it
> effectively as an INNER JOIN.
> a) Is this correct?
Not really, no.
MySQL treats "," as a CROSS JOIN, which
James Sheridan
<[EMAIL PROTECTED]> wrote:
> The query should have been:
>
> SELECT Q.*
> FROM Query Q,
> UserQuery UQ
> WHERE Q.type = 'a' OR
> (Q.id = UQ.queryID AND
> UQ.userID = '1');
Well, it's the same thing: for each row in Q with Q.type = 'a', you will
get as many copies of this row as the
James Sheridan wrote:
> CREATE TABLE [Query] (
> [id] INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
> [creatorID] INTEGER NOT NULL,
> [ownerID] INTEGER NOT NULL,
> [type] VARCHAR NOT NULL
> );
> CREATE TABLE [UserQuery] (
> [userID] INTEGER NOT NULL,
> [que
James Sheridan
<[EMAIL PROTECTED]> wrote:
> CREATE TABLE [Query] (
> [id] INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
> [creatorID] INTEGER NOT NULL,
> [ownerID] INTEGER NOT NULL,
> [type] VARCHAR NOT NULL
> );
> CREATE TABLE [UserQuery] (
> [userID] INTEGER NOT NULL,
> [queryID] INTEGER NOT
CREATE TABLE [Query] (
[id] INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
[creatorID] INTEGER NOT NULL,
[ownerID] INTEGER NOT NULL,
[type] VARCHAR NOT NULL
);
CREATE TABLE [UserQuery] (
[userID] INTEGER NOT NULL,
[queryID] INTEGER NOT NULL
);
SEL
5 matches
Mail list logo