RE: SQL Statement Help

2005-12-14 Thread Charles Walmsley
best wishes Ch -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of [EMAIL PROTECTED] Sent: 14 December 2005 19:22 To: Jesse Cc: mysql@lists.mysql.com Subject: Re: SQL Statement Help "Jesse" <[EMAIL PROTECTED]> wrote on 12/14/2005 02:03:22 P

Re: SQL Statement Help

2005-12-14 Thread SGreen
"Jesse" <[EMAIL PROTECTED]> wrote on 12/14/2005 02:03:22 PM: > Hello, > I need help building a SQL Statement. I'm currently using MySQL > 5.something. This one is kind of strange, and I can't seem to figure out > how to do it. > > I have a table named Participants. Each Participant is allowe

Re: SQL Statement Help

2005-12-14 Thread Martijn Tonies
> Hello, > I need help building a SQL Statement. I'm currently using MySQL > 5.something. This one is kind of strange, and I can't seem to figure out > how to do it. > > I have a table named Participants. Each Participant is allowed to bring up > to 5 Guests. Instead of putting the names in a

SQL Statement Help

2005-12-14 Thread Jesse
Hello, I need help building a SQL Statement. I'm currently using MySQL 5.something. This one is kind of strange, and I can't seem to figure out how to do it. I have a table named Participants. Each Participant is allowed to bring up to 5 Guests. Instead of putting the names in a separate t

Re: SQL statement help

2005-10-17 Thread SGreen
D = 0 > > > >J.R. > > > >-Original Message- > >From: C.F. Scheidecker Antunes [mailto:[EMAIL PROTECTED] > >Sent: Sunday, October 16, 2005 1:45 PM > >To: mysql@lists.mysql.com > >Subject: SQL statement help > >Importance: High > > >

Re: SQL statement help

2005-10-17 Thread Terence
it for you. UPDATE table_one t1, table_two t2 SET t1.ID = t2.ID WHERE t2.num = t1.num AND t1.ID = 0 J.R. -Original Message- From: C.F. Scheidecker Antunes [mailto:[EMAIL PROTECTED] Sent: Sunday, October 16, 2005 1:45 PM To: mysql@lists.mysql.com Subject: SQL statement help Importance

Re: SQL statement help

2005-10-16 Thread C.F. Scheidecker Antunes
PROTECTED] Sent: Sunday, October 16, 2005 1:45 PM To: mysql@lists.mysql.com Subject: SQL statement help Importance: High Hello All, I have two MySQL 4.1 tables. The first table has an ID field which is set to zero. The second one has ID fields and filenames. I need a single SQL statement to set the

Re: SQL statement help

2005-10-16 Thread C.F. Scheidecker Antunes
statement help Importance: High Hello All, I have two MySQL 4.1 tables. The first table has an ID field which is set to zero. The second one has ID fields and filenames. I need a single SQL statement to set the ID from table 1 to the ID from table 2 ONLY IF the ID on one is zero. That is, if the ID on

RE: SQL statement help

2005-10-16 Thread J.R. Bullington
: mysql@lists.mysql.com Subject: SQL statement help Importance: High Hello All, I have two MySQL 4.1 tables. The first table has an ID field which is set to zero. The second one has ID fields and filenames. I need a single SQL statement to set the ID from table 1 to the ID from table 2 ONLY IF the

SQL statement help

2005-10-16 Thread C.F. Scheidecker Antunes
Hello All, I have two MySQL 4.1 tables. The first table has an ID field which is set to zero. The second one has ID fields and filenames. I need a single SQL statement to set the ID from table 1 to the ID from table 2 ONLY IF the ID on one is zero. That is, if the ID on table one is not set (

Re: SQL Statement Help - Is this possible?

2003-12-11 Thread spamtrap
S B) AND NOT EXISTS ( SELECT * FROM load_cntl AS B WHERE B.LOAD_DATE = DATEADD(A.LOAD_DATE, 1) ) Good Luck! Charlie [EMAIL PROTECTED]/Shield/Michigan > From: Mark Marshall Date: December 10 2003 6:01pm > Subject: SQL Statement Help - Is this possible? > > I have

SQL Statement Help - Is this possible?

2003-12-10 Thread Mark Marshall
I have a database table that has one row entered every day by the user. If the user skips a day, it throws off our monthly totals. Assume a table with four columns: id (which is the key), date (-mm-dd), data1 (int), data2 (int) Is there a way to say "Select the first missing date in the

re: newbie sql statement help

2003-02-11 Thread The Mindflayer
This might help. http://www.mysql.com/doc/en/example-Maximum-column-group-row.html I had the same problem. Before I found the webpage above, I went with a less efficient but simpler way. I wanted the highest revision ("revision") for each news article ("id"). $SQL = "CREATE TEMPORARY TABLE

newbie sql statement help

2003-02-11 Thread Bob Ramsey
The people who run our mysql server are using version 3.23.51, so I don't have access to some of version 4's features like sub selectes. I have a table with data like this: firm firm_rank time time_rank student A 1 10 1 jones A 1 10 1 smith A 1 10 1 alvin A 2 10 1 bob A 2 10 2 charlie