eone please help me with this one?
>
> I'm trying to SELECT from a table only those records that have a record,
> matching a search term, in a table related by a many to many relationship.
> The many to many relationship is in a mapping/junction table.
>
>
Can someone please help me with this one?
I'm trying to SELECT from a table only those records that have a record,
matching a search term, in a table related by a many to many
relationship. The many to many relationship is in a mapping/junction table.
Here's an example of what I h
Responses inline...
On Tue, Sep 30, 2008 at 9:21 AM, Weston, Craig (OFT)
<[EMAIL PROTECTED]> wrote:
>
> Rob,
> I tried this on the small test data, a larger data set and it appears to
> make my day. I sincerely appreciate your willingness to help me out.
>
> I do have some questions, mostly so I c
k you.
-Original Message-
From: Rob Wultsch [mailto:[EMAIL PROTECTED]
Sent: Tuesday, September 30, 2008 10:11 AM
To: Weston, Craig (OFT)
Cc: mysql@lists.mysql.com
Subject: Re: Many to many to too many relation.
Luck for you my vpn appears to be screwed up. Here is a stored proc I
whipp
Wow, I do feel very lucky. I am only at the "this is a cursor" part.
I sincerely appreciate your help.
-Original Message-
From: Rob Wultsch [mailto:[EMAIL PROTECTED]
Sent: Tuesday, September 30, 2008 10:11 AM
To: Weston, Craig (OFT)
Cc: mysql@lists.mysql.com
Subject: R
> From: Rob Wultsch [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, September 30, 2008 3:30 AM
> To: Weston, Craig (OFT)
> Cc: mysql@lists.mysql.com
> Subject: Re: Many to many to too many relation.
>
> I tried reading this and it took much brain power to do for free. I
>
his e-mail or its
> attachments. Please notify the sender immediately by reply e-mail and
> delete the e-mail from your system.
>
>
> -Original Message-
>
> From: Rob Wultsch [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, September 30, 2008 3:30 AM
> To: Weston, Crai
from your system.
-Original Message-
From: Rob Wultsch [mailto:[EMAIL PROTECTED]
Sent: Tuesday, September 30, 2008 3:30 AM
To: Weston, Craig (OFT)
Cc: mysql@lists.mysql.com
Subject: Re: Many to many to too many relation.
I tried reading this and it took much brain power to do for free. I
, Craig (OFT)
Cc: mysql@lists.mysql.com
Subject: Re: Many to many to too many relation.
I tried reading this and it took much brain power to do for free. I
suggest breaking this down into the simplest possible example you can.
Ideally have an create table statement, and insert with a small amount
of
I tried reading this and it took much brain power to do for free. I
suggest breaking this down into the simplest possible example you can.
Ideally have an create table statement, and insert with a small amount
of data (as simple as possible), a simple psuedo code query and
example output of what yo
Hello everyone.
I have a complex situation. I have a list of related records (see
partial extract below) where I am trying to determine the unique lowest
number for each relation. This number should always be an AB number,
since all the MA numbers will always relate to an AB number. I need the
,car
parts)[/b]
the last new requeriment was that a wonderful
1 CabeceraComprobanteVenta can sell/contain [b]many items[/b] ArticuloNoAuto
(1-4)
and 1 ArticuloNoAuto can be contained in 1 to 2 CabeceraComprobanteVenta
(normal)
or (canceled,newnormal)
so we have a relation many-to-many already res
Robert MannI wrote:
Hello!
I have three tables, mapping out a n:n relationship of authors and the
books they worked on:
table 1: authors (id, name)
table 2: authorships (author_id, book_id)
table 3: books (id, name, bestseller tinyint)
Here's two different queries I want to run:
1. Select eac
Hello!
I have three tables, mapping out a n:n relationship of authors and the
books they worked on:
table 1: authors (id, name)
table 2: authorships (author_id, book_id)
table 3: books (id, name, bestseller tinyint)
Here's two different queries I want to run:
1. Select each author, and how man
gt;
> -
>
> Rapthor wrote:
>> Hi SQLers,
>>
>> I am searching for an SQL command to combine several many-to-many
>> queries.
>> At the end I only want to get results suitable for all restrictions.
>>
>> Better show you my tables:
>>
&
p'; it's a reserved word.
PB
-
Rapthor wrote:
Hi SQLers,
I am searching for an SQL command to combine several many-to-many queries.
At the end I only want to get results suitable for all restrictions.
Better show you my tables:
USER
id name
1 frank
ROLE
id name
1 admin
2 gene
Hi SQLers,
I am searching for an SQL command to combine several many-to-many queries.
At the end I only want to get results suitable for all restrictions.
Better show you my tables:
USER
id name
1 frank
ROLE
id name
1 admin
2 general
GROUP
id name
1 groupA
2 groupB
USER_ROLE
gerald_clark wrote:
I've checked the archives and found an explanation as to how the
check if a record is not in a many-to-many table. The answer to
that is somewhat simple and clear to me. But here's my problem: how
do you check if a record doesn't have a *particula
I've checked the archives and found an explanation as to how the
check if a record is not in a many-to-many table. The answer to that
is somewhat simple and clear to me. But here's my problem: how do
you check if a record doesn't have a *particular* many-to-many
relat
Marco,
I've checked the archives and found an explanation as to how the check
if a record is not in a many-to-many table. The answer to that is
somewhat simple and clear to me. But here's my problem: how do you
check if a record doesn't have a *particular* many-to-many
relat
Hey all,
I've checked the archives and found an explanation as to how the check
if a record is not in a many-to-many table. The answer to that is
somewhat simple and clear to me. But here's my problem: how do you
check if a record doesn't have a *particular* many-to-many
re
run out of places to look,
> sorry. I can't seem to find this anywhere, although I'm certain I've seen it
> before.
>
> How can I identify all the records in a table that are not referenced in a
> many-to-many table?
>
> I have a [unique] table of files and a
> >
> > Am Saturday 25 March 2006 19:10 schrieb barney:
> > > Folk,
> > >
> > > This may be off-base for this list, but I've run out of places to look,
> > > sorry. I can't seem to find this anywhere, although I'm certain I've
>
ain I've seen it
> before.
> How can I identify all the records in a table that are not referenced in a
> many-to-many table?
> I have a [unique] table of files and a [unique] table of attributes. These
> are linked in a merge table which is many-to-many. I need to
barney wrote:
Thanks, Stefan,
But that only works if both tables have the same field name, doesn't it? If I
use select FileKey from dl_files left join dl_merges using (FileID) where
FileID is null MySQL returns
Unknown column 'articles.dl_files.FileID' in 'on clause'.
Correct me if I'm wrong,
nd this anywhere, although I'm certain I've seen
it before.
How can I identify all the records in a table that are not referenced in a
many-to-many table?
I have a [unique] table of files and a [unique] table of attributes. These
are linked in a merge table which is many-to-many. I need t
t; > This may be off-base for this list, but I've run out of places to look,
> > sorry. I can't seem to find this anywhere, although I'm certain I've seen
> > it before.
> >
> > How can I identify all the records in a table that are not reference
to find this anywhere, although I'm certain I've seen
> it before.
>
> How can I identify all the records in a table that are not referenced in a
> many-to-many table?
>
> I have a [unique] table of files and a [unique] table of attributes. These
> are linked in a m
Folk,
This may be off-base for this list, but I've run out of places to look, sorry.
I can't seem to find this anywhere, although I'm certain I've seen it before.
How can I identify all the records in a table that are not referenced in a
many-to-many table?
I have a [un
oops! I hit SEND before I was done. (BAD FINGERS!)
SELECT *
FROM movies
LEFT JOIN director_movies
ON director_movies.movie_id=movies.id
LEFT JOIN director
ON director_movies.director_id = director.id
LEFT JOIN country_movies
ON country_movies.movie_id=movies.id
LEFT JOIN country
t;> `producer_id` int(11) NOT NULL default '0'
> >>> ) ENGINE=InnoDB DEFAULT CHARSET=latin1
> >>>
> >>> Again, I'm trying to select from movies,director, and producer,
>
Oops, I meant to send this to the list so that all could benefit.
--
Rhino
- Original Message -
From: "Rhino" <[EMAIL PROTECTED]>
To: "Jessica Yazbek" <[EMAIL PROTECTED]>
Sent: Sunday, February 12, 2006 4:19 PM
Subject: Re: Multiple many-to-many SELECT
Maybe I'm using the
wrong keywords. In any event, I am desperate for help. Here is my
problem:
I have a database with several tables related on a many-to-many
basis. Here is a simplified description:
TABLE: movies
+
has
been trying to do the same thing that I am. Maybe I'm using the
wrong keywords. In any event, I am desperate for help. Here is my
problem:
I have a database with several tables related on a many-to-many
basis. Here is a simplified description:
TABLE: movies
+-+
tween each many-to-many relationship.
The tables are as follows:
movies
director
producer
director_movies (relates director.id to movies.id)
producer_movies (relates producer.id to movies.id)
I'm hoping for a way to select movies.*, director.* and producer.*
using only the movies.id fie
.html
Note the link at the bottom of that page to "Data Modeling as part of
Database Design". That whole site is really good, actually.
-Sheeri
On 2/9/06, Rhino <[EMAIL PROTECTED]> wrote:
> Jessica,
>
> It think your first mistake is that you are trying to implemen
Jessica,
It think your first mistake is that you are trying to implement many-to-many
relationships directly. Although it is theoretically possible to do so, I've
never seen anyone do it myself. I believe the normal approach is to break
each many-to-many relationship into two one-to
I have a database with several tables related on a many-to-many
basis. Here is a simplified description:
TABLE: movies
+-+-+--+-+-+---+
| Field | Type| Null | Key | Defau
because they both try to conform to the same
standards.
Rhino
- Original Message -
From: "Perry Merritt" <[EMAIL PROTECTED]>
To:
Sent: Wednesday, April 20, 2005 11:36 PM
Subject: many to many
> Hi, I'm a novice.
>
> I've designed a database that supports ma
On 21/04/2005 3:36 p.m., Perry Merritt wrote:
Hi, I'm a novice.
Hi Perry,
I've designed a database that supports many to many relationships (actually many to many to many) and I need help creating the query to find my data. I know things like JOINs exist, but don't have a clue
t;
> I've designed a database that supports many to many relationships (actually
> many to many to many) and I need help creating the query to find my data. I
> know things like JOINs exist, but don't have a clue how to use them.
>
> I have three main tables and two link
Hi, I'm a novice.
I've designed a database that supports many to many relationships (actually
many to many to many) and I need help creating the query to find my data. I
know things like JOINs exist, but don't have a clue how to use them.
I have three main tables and two l
- Original Message -
From: "Emily Lena Jones" <[EMAIL PROTECTED]>
To: "Rhino" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Thursday, October 28, 2004 7:46 PM
Subject: Re: many-to-many query
>
> Quoting Rhino <[EMAIL PROTECTED]>:
>
Quoting Rhino <[EMAIL PROTECTED]>:
> I wasn't sure if you understood the concept of association tables so forgive
> me if I told you things you already knew; I didn't mean to be patronizing.
No problem--you weren't patronizing at all, and I did tell you I was new at
this!
> With respect to you
- Original Message -
From: "Emily Lena Jones" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, October 28, 2004 4:05 PM
Subject: many-to-many query
> Hi, I'm totally new at this so have no idea whether I'm asking for
something
> easy o
http://dev.mysql.com/doc/mysql/en/JOIN.html
-Original Message-
From: Emily Lena Jones [mailto:[EMAIL PROTECTED]
Sent: Thursday, October 28, 2004 1:05 PM
To: [EMAIL PROTECTED]
Subject: many-to-many query
Hi, I'm totally new at this so have no idea whether I'm asking for somethi
Hi, I'm totally new at this so have no idea whether I'm asking for something
easy or quite difficult.
I am working in MySQL 3.23.58/PHP and am trying to construct a rather complex
query. I have three tables: resources (containing resid, descr, title, url),
topicdir (containing topicid, resid) and
>
Cc: <[EMAIL PROTECTED]>
Sent: Tuesday, October 26, 2004 6:41 PM
Subject: Re: Querying on subsets of one-to-many and many-to-many
> OK, now that I have a better model to work with, let me try again. (And
> stop being so discouraged! This is hard for everyone until they get the
>
isputable of course)
impossibility
> of this thing using one trip only.
>
> Daniel
>
> - Original Message -
> From: <[EMAIL PROTECTED]>
> To: "Daniel BODEA" <[EMAIL PROTECTED]>
> Cc: <[EMAIL PROTECTED]>
> Sent: Tuesday, October 26, 200
to myself the (disputable of course) impossibility
of this thing using one trip only.
Daniel
- Original Message -
From: <[EMAIL PROTECTED]>
To: "Daniel BODEA" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Tuesday, October 26, 2004 3:41 PM
Subject: Re: Query
Under most circumstances, even with data tables as large as yours, I have
found that direct JOIN statements have provided acceptable performance. On
certain highly normalized databases, where the requirements of the query
needed more than 4 or 5 tables joined at once, I have also used your
"cac
Greetings,
I have several solutions to a problem which requires temporary or cache
tables but the different solutions are time consuming to test for
performance and I was wondering if anyone had more information on this than
myself.
The server is 3.23.40 without possibility for upgrade to 4.x bec
I have, to make it clear, 2 many-to-many relationships for table person:
PersonPerson_Club ClubPerson_Creditcard
CreditCard
IL PROTECTED]>
Sent: Saturday, August 28, 2004 6:08 PM
Subject: Re: Many to Many: Does this make sense ?
> Okay, hopefully I'm somewhat clearer today. I doubt
> it but the effort is going to be made regardless.
>
> First off, Rhino I read through your last post,
> regardin
f you have definitely abandoned
> it. Maybe we can critique
> that design for you and help you improve it or at
> least avoid the most
> common pitfalls.
>
> Rhino
>
>
>
>
> - Original Message -
> From: "Stuart Felenstein" <[EMAIL PROTECTED]>
As for the RAD tool I'm open to suggestions, but I
think I've read about them all. PHP - MySQL platform.
Does it have to be PHP? If a java RAD is ok I would suggest
http://jdbforms.sourceforge.net/
It does not allow multiple inserts from one page, BUT you can:
1) tack in some html (text area o
From: "Stuart Felenstein" <[EMAIL PROTECTED]>
To: "Rhino" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>; "Stuart Felenstein" <[EMAIL PROTECTED]>
Sent: Friday, August 27, 2004 4:47 PM
Subject: Re: Many to Many: Does this make se
uart Felenstein" <[EMAIL PROTECTED]>
> To: "Rhino" <[EMAIL PROTECTED]>;
> <[EMAIL PROTECTED]>
> Cc: <[EMAIL PROTECTED]>; "Stuart Felenstein"
> <[EMAIL PROTECTED]>
> Sent: Friday, August 27, 2004 3:05 PM
> Subject: Re: Many to
My replies are interspersed below.
Rhino
- Original Message -
From: "Stuart Felenstein" <[EMAIL PROTECTED]>
To: "Rhino" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>; "Stuart Felenstein" <[EMAIL PROTECTED]>
take. Plus the lack it would still
leave.
I'm going to go over my schema though and see where
the many to many relationships will work well for me.
I'm assuming telephone numbers (SL Green's example)
that are specific to the user / member need not
necessarily be broken out ? P
Shawn,
Yes, we *are* on the same page, now that I understand that you didn't mean to
implement the many-to-many relationship in a single table.
Stuart,
Read what Stuart has described in this note. The association table is the one he calls
TItle_Member. This table is *crucial* to the d
Rhino,
You and I are on the same page. I also never seen a "true many-to-many"
relationship in database design. The closest approximation I have seen is
the 3 table design like you and I have both proposed. It's the only way I
have ever seen to model a many-to-many design, that
rim" table that must
exist in the many to many / one to many design makes
no sense to me. I guess it serves as some type of
support structure ?
I agree that it would be better to have a list
prepared for users to choose from. I'm working on a
job board. Looking out on the vast sea of c
My remarks are interspersed below for reasons which will probably be obvious.
Rhino
- Original Message -
From: [EMAIL PROTECTED]
To: Stuart Felenstein
Cc: [EMAIL PROTECTED] ; Peter Brawley ; Rhino
Sent: Friday, August 27, 2004 12:33 PM
Subject: Re: Many to Many: Does this
is
the way it is.
Rhino
- Original Message -
From: "Stuart Felenstein" <[EMAIL PROTECTED]>
To: "Rhino" <[EMAIL PROTECTED]>; "Peter Brawley"
<[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Friday, August 27, 2004 11:47 AM
Subject: Re: Many t
7;s a
business rule and you code for that above the database (either in your
validation code or, in this case, through UI design)
I would stick with the many-to-many database design as you don't want
people mis-typing titles all of the time:"Godfather" is not "The
Godfathe
ROTECTED]> wrote:
>
> - Original Message -
> From: "Stuart Felenstein" <[EMAIL PROTECTED]>
> To: "Peter Brawley"
> <[EMAIL PROTECTED]>;
> <[EMAIL PROTECTED]>
> Sent: Friday, August 27, 2004 10:06 AM
> Subject: Re: Many to Ma
- Original Message -
From: "Stuart Felenstein" <[EMAIL PROTECTED]>
To: "Peter Brawley" <[EMAIL PROTECTED]>;
<[EMAIL PROTECTED]>
Sent: Friday, August 27, 2004 10:06 AM
Subject: Re: Many to Many: Does this make sense ?
> Thank you for the "
quot;. To
> >allow 5 titles I need 5 pages. From a users
> >standpoint, it's not horrible, but not the best.
>
> >So, now I'm podering a Many to Many, but I realize
> >there would need to be multiple Member_Title
> tables,
> >Member_Title1, Member_Title
same table on one "page". To
>allow 5 titles I need 5 pages. From a users
>standpoint, it's not horrible, but not the best.
>So, now I'm podering a Many to Many, but I realize
>there would need to be multiple Member_Title tables,
>Member_Title1, Member_Title2, M
to capabilities to allow multiple insert
transactions into the same table on one "page". To
allow 5 titles I need 5 pages. From a users
standpoint, it's not horrible, but not the best.
So, now I'm podering a Many to Many, but I realize
there would need to be multiple Membe
Harald Fuchs wrote:
> That's easy:
[Excellent MySQL code example snipped]
Thanks, that was exactly what I was looking for.
/mac
-
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://li
Thanks for your reply,
Diana Soares wrote:
> > Selecting manufacturers from just one color with join works like a charm.
> > (IIRC, untested code:)
> >
> > SELECT DISTINCT ca.Manufacturer, co.Name FROM car_color_links as l
> > JOIN colors as co ON (co.ID = l.color_ID)
Hi,
On Thu, 2003-02-20 at 13:20, Mac wrote:
> Hi,
>
> I am using MySQL v3.23 and have a many-to-many relationship (cars <->
> colors) that I have broken up into three tables as follows
>
> cars:
> ID Manufacturer
> 1 Volvo
> 2 BMW
I don't have a mailing list, and I don't appreciate your email.
You subscribed to the mysql mailing list, or you would not be getting it.
The instructions to unsubscribe are at the bottom of every message.
Kip McGee wrote:
will you please take me off of your mailing list if you dont im gonna
se
Hi,
I am using MySQL v3.23 and have a many-to-many relationship (cars <->
colors) that I have broken up into three tables as follows
cars:
ID Manufacturer
1 Volvo
2 BMW
3 Toyota
On Wed, Feb 19, 2003 at 08:13:12AM -0600, gerald_clark wrote:
>
> Looks to my like skuagent should be using the varchar fields instead of
> the int fields.
> Then you could just insert ignore each line from your test file.
>
> Paul Chvostek wrote:
>
> >Hi all.
> &
Looks to my like skuagent should be using the varchar fields instead of
the int fields.
Then you could just insert ignore each line from your test file.
Paul Chvostek wrote:
Hi all.
I need some help figuring out how to update a many-to-many relationship
from a text file.
For the fun of it
Hi all.
I need some help figuring out how to update a many-to-many relationship
from a text file.
For the fun of it, let's call the tables 'sku' and 'agent'. Each sku
can have multiple agents (usually < 10, always > 0), and each agent can
be associated with an u
but i'm 97% that it
works... ofcource You have to modify the query to match Your DB layout
=d0Mi=
- Original Message -
From: "Matthew Smith" <[EMAIL PROTECTED]>
To: "mysql" <[EMAIL PROTECTED]>
Sent: Thursday, April 18, 2002 8:04 AM
Subject: Re: [MANY
MySQL AFAIK.
>
> I am not quite sure what you mean... but here is my take anyways. Is this
> going around my elbow? Or is this just how you do relationals in SQL?
>
This is a standard way of doing many-to-many relationships in SQL; there
may be others.
> (For each relationship
> ...So the table song_x_artist contains references to all artists in a
> song and vice-versa. (Field names correspond between tables.)
How does song_x_artist reference the other databases? Is there a way to set
up a field to always be a reference to another table?
I am not quite sure what you
on or helped compose.
hth,
Arthur
- Original Message -
From: "Robbie Newton" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, April 17, 2002 10:25 PM
Subject: [MANY to MANY] relationship with MySQL ???
> Hello all,
>
> [~~I guess I could do so
Hi Robbie, all
I have lots of things that need many to many - the way that I do it is this:
create table artists (
a_ser
int unsigned not null primary key auto_increment,
artist_name varchar(64),
other stuff...
);
create table songs (
s_ser int unsigned not null primary key auto_increment
rtists featured in that
song in the window that loads up. I am not sure how to set this up. It would
be a many to many relationship I think...
(one given artist could be featured on many different songs)
[many]
to
(one given song could have many featured artists) [many]
My first thout of how to
I can't figure out how to formulate a query to retrieve a certain set of
data. I have two tables in a many-to-many relationship with each other
via a linking table. I want to get a list of the records in the first
table which have no matching records of a certain value in the second
an example) the
> joins ID_weight_measure with the related symbol, and
> the ID_height_measure with its symbol?
> I don't know if it's a many-to-many relationship, and
> even if it is, I don't know how to implement it.
> I hope in your help.
select p.id_weight_measure,
elect
statement both (or any...this is only an example) the
joins ID_weight_measure with the related symbol, and
the ID_height_measure with its symbol?
I don't know if it's a many-to-many relationship, and
even if it is, I don't know how to implement it.
I
> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Benjamin
> Hi.
>
> On Mon, Oct 01, 2001 at 07:54:37PM -0700, [EMAIL PROTECTED] wrote:
> >
> > Hi there,
> >
> > I have a many-to-many relationship:
> >
Hi.
On Mon, Oct 01, 2001 at 07:54:37PM -0700, [EMAIL PROTECTED] wrote:
>
> Hi there,
>
> I have a many-to-many relationship:
>
> ind table
> -
> id = 4, name = Joe
> id = 5, name = Jane
>
> bus_ctr table
> -
> id = 1, name = downt
Hi there,
I have a many-to-many relationship:
ind table
-
id = 4, name = Joe
id = 5, name = Jane
bus_ctr table
-
id = 1, name = downtown mall
id = 2, name = sunshine mall
id = 3, name = express shop
mm_ind_bus_ctr table (many to many association table
t11, table 2 as t2
where t1.blah = t11.blah and t1.blah = t2.blah;
Or something to that effect.
Cal
*
* Cal Evans
* Senior Internet Dreamer
* http://www.calevans.com
*
- Original Message -
From: "Nick Davies" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday,
Hi,
I'm have a bit of difficulty with a many to many join on two
tables. (Where an item is directly related to another item of the same
type in the same table).
I'm trying to use the same method as a join between 2 tables with
a 3rd but having no joy. Help :)
Hello,
I need help with a select statement on my database. (I am still on L Plates
with Mysql)
My Tables
Clients - Holds clients infomation
Targets - Holds Target infomation
Clients_Targets - Holds Clients Id and Targets Id
How do I find clients that are in muti
"Mysql" <[EMAIL PROTECTED]>
Sent: Sunday, July 08, 2001 2:08
Subject: Help - Selecting from many to many table.
> Hello,
>
> I am new to SQL and just learning.
>
> I have a table of clients and a table of targets. I have a
clients_targets
> table holding the ke
Hello,
I am new to SQL and just learning.
I have a table of clients and a table of targets. I have a clients_targets
table holding the keys for relating.
I am having troble trying to select clients that are in more than one
target.
Eg. Select c.First_Name, ... From clients as c, clients_targ
Hello again
here send al SQL to generate the database to test in MYSQL,
for example in case that I Question in the query that a Productor
TECUN (1) no cant be return, pepe(2), lolo(1)
CEIS (2) no cant be return lolo(1)
PCMAX (3) no cant be return pepe(2)
A Numbres are the ID In the table cp th
inal Message-
From: Rus [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, January 31, 2001 2:11 AM
To: [EMAIL PROTECTED]
Subject: Re: AND on a many to many table, with arbitrary ANDs
I think you could use 'WHERE catid IN'
For example, on PHP
$catlist="1,2,3,4,5";
... select ... wher
>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, January 31, 2001 7:50 AM
Subject: AND on a many to many table, with arbitrary ANDs
> Hello everyone,
>
> I am in the process of building a search engine on a database. I have two
> tables that have a many-to-many relationship: A s
ar
more simultaneous enquiries that way than it will with a single complex
SQL query.
Hope this helps some.
The Hooker
--
"I've had a perfectly wonderful evening, but this wasn't it"
> I am in the process of building a search engine on a database. I have two
> tables that h
1 - 100 of 102 matches
Mail list logo