Jens Kleikamp schrieb:
hi to all,
I have a simple question/szenario.
Here are my tables:
1. image (id, name)
2. tag (id, name)
3. images_tags (image_id, tag_id)
At the moment I have the following working query, it selects all images
which have *at least one of the tag ids* (25,30) assigned.
hi to all,
I have a simple question/szenario.
Here are my tables:
1. image (id, name)
2. tag (id, name)
3. images_tags (image_id, tag_id)
At the moment I have the following working query, it selects all images
which have *at least one of the tag ids* (25,30) assigned.
SELECT DISTINCT image.
Josh,
>I have several tables, all with many-to-many joining tables.
> users
> users_teams
> teams
> teams_projects
> projects
Once again explicit join syntax clarifies matters:
SELECT DISTINCT username
FROM users
INNER JOIN users_teams ON (users.id = users_teams.user_id)
INNER JOIN teams ON
>since I'm not sure how users would
> ever be directly associated with teams - I would have expected to find
> players to be associated with teams - so forgive me if this doesn't
> resemble very much what you're doing:
Think corporate projects, not sports.
Here's my take on the original query.. y
Oops, I meant to copy the mailing list on this reply.
Rhino
- Original Message -
From: "Rhino" <[EMAIL PROTECTED]>
To: "Josh Mellicker" <[EMAIL PROTECTED]>
Sent: Saturday, December 24, 2005 9:24 AM
Subject: Re: MySQL query question
- Ori
I have several tables, all with many-to-many joining tables.
users
users_teams
teams
teams_projects
projects
---
So, with a projects.id = 1, I want to get all the usernames of people
on teams assigned to that project.
SELECT DISTINCT username
FROM users, users_teams, teams, projects_te
Chris,
You're almost there!
select * from temp where col2 like concat('%',col1, '%');
Andy
> -Original Message-
> From: Chris A. Mattingly [mailto:[EMAIL PROTECTED]
> Sent: 07 November 2003 17:01
> To: [EMAIL PROTECTED]
> Subject: MySQL query qu
I've searched around on the lists archives and even did some googling, but I'm
having trouble finding the answer to this question.
Given that I have a table with 2 columns (say col1, col2) I want to be able to
search for the value of col1 in the value of col2. Let's say that in one
instance co
Sorry,
I've been too long in a list where you just answer the questioner and
then the questioner writes a summary of the answers to the list.
Sabine
Sabine Richter wrote:
>
> Hello Taylor,
>
> as far as I see from the documentation and own trials you can just
> delete from table where conditio
How can I delete from a table the results of a join query..
I.e, join two tables together, get the resutls, now want to delete that data from one
of the tables...
Do I have to create a tempory table, hold the data, and delete from the one table data
matching in the temp table,
or can I just co
10 matches
Mail list logo