Re: delete record that passed > 1 day

2004-06-07 Thread Michael Stassen
starofframe wrote: Thanks a lot Mike... what's a clear explanation... You're welcome. Actually I have used WHERE crea_dt + interval 1 day < curdate() before I read ur reply ...but now I guess I better change it to WHERE crea_dt>curdate-interval 1 day That's probably just a typo, but just in case, y

Re: delete record that passed > 1 day

2004-06-07 Thread starofframe
Thanks a lot Mike... what's a clear explanation... Actually I have used WHERE crea_dt + interval 1 day < curdate() before I read ur reply ...but now I guess I better change it to WHERE crea_dt>curdate-interval 1 day again thanks a lot... and thanks to Jeff too. Sukanto -- MySQL General Mailing L

Re: delete record that passed > 1 day

2004-06-07 Thread Michael Stassen
Jeff Smelser wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Monday 07 June 2004 10:03 pm, starofframe wrote: but delete from table where date_sub(crea_dt, interval 1 day) Here: http://dev.mysql.com/doc/mysql/de/Date_and_time_functions.html I gave you the function.. You can figure out how m

Re: delete record that passed > 1 day

2004-06-07 Thread Jeff Smelser
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Monday 07 June 2004 10:03 pm, starofframe wrote: > but > delete from table where date_sub(crea_dt, interval 1 day) should delete all data right??? > All I want is compared to date_now > eg : now is 2004-6-8 and all I want to delete is data t

Re: delete record that passed > 1 day

2004-06-07 Thread starofframe
Yes, I did found out just now... but delete from table where date_sub(crea_dt, interval 1 day) To: <[EMAIL PROTECTED]> Sent: Tuesday, June 08, 2004 9:41 AM Subject: Re: delete record that passed > 1 day -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Monday 07 June 2004 09:22 pm, Jef

Re: delete record that passed > 1 day

2004-06-07 Thread Jeff Smelser
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Monday 07 June 2004 09:22 pm, Jeff Smelser wrote: > On Monday 07 June 2004 09:25 pm, starofframe wrote: > > Hi Jeff, > > you mean I can use sql like this > > DELETE FROM table where date_sub(crea_dt, interval 1 day) > > Add: > crea_dt Could be

Re: delete record that passed > 1 day

2004-06-07 Thread Jeff Smelser
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Monday 07 June 2004 09:25 pm, starofframe wrote: > Hi Jeff, > you mean I can use sql like this > DELETE FROM table where date_sub(crea_dt, interval 1 day) Add: > crea_dt - -- Anything worth fighting for is worth fighting dirty for.

Re: delete record that passed > 1 day

2004-06-07 Thread starofframe
Hi Jeff, you mean I can use sql like this DELETE FROM table where date_sub(crea_dt, interval 1 day) thanks a lot Sukanto - Original Message - From: "Jeff Smelser" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Tuesday, June 08, 2004 8:55 AM Subject: Re: del

Re: delete record that passed > 1 day

2004-06-07 Thread Jeff Smelser
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Monday 07 June 2004 08:36 pm, starofframe wrote: > description like this : if now()-crea_dt > 0 then delete select date_sub(crea_dt, interval 1 day) - -- "If you're like me, and I know *I* am..." -- Joel Robinson -BEGIN PGP SIGNATURE---

delete record that passed > 1 day

2004-06-07 Thread starofframe
Hi all, I have mysql table that has a field named 'crea_dt' (it records the creation date of data)... I want to delete records that have passed for more than a day description like this : if now()-crea_dt > 0 then delete But I just can't find the suitable mysql command for this function. Anyo

Re: [SQL]how to delete record where I reference to other table

2003-11-20 Thread Egor Egorov
"Kim G. Pedersen" <[EMAIL PROTECTED]> wrote: > Has look alot around , and tried a lot without success > > how to do this : > Delete from pproductMix PM where PM.mixID in (select ID from pmix > where mixno=72000) > > I would like a solution with and without subqueries > DELETE FROM pproductMi

[SQL]how to delete record where I reference to other table

2003-11-20 Thread Kim G. Pedersen
Hi Has look alot around , and tried a lot without success how to do this : Delete from pproductMix PM where PM.mixID in (select ID from pmix where mixno=72000) I would like a solution with and without subqueries thanks Kim G. Pedersen macaos/elprint Development +45 35373808 -- MySQL Gen

RE: delete record

2003-06-12 Thread Christopher Knight
:20 AM To: [EMAIL PROTECTED] Subject: delete record Hi, I've done these operations: - I deleted one record - I didn't execute "optimize table" Do you know if it's possible to undelete the record? Many thanks Arcangelo -- MySQL General Mailing List For list archive

RE: delete record

2003-06-12 Thread Mike Hillyer
- From: Arcangelo [mailto:[EMAIL PROTECTED] Sent: Thursday, June 12, 2003 9:20 AM To: [EMAIL PROTECTED] Subject: delete record Hi, I've done these operations: - I deleted one record - I didn't execute "optimize table" Do you know if it's possible to undelet

delete record

2003-06-12 Thread Arcangelo
Hi, I've done these operations: - I deleted one record - I didn't execute "optimize table" Do you know if it's possible to undelete the record? Many thanks Arcangelo

RE : RE : Duplicate key delete record with same key

2002-11-21 Thread BPF Webmaster
the old record is deleted before the new record is inserted. >> So the result was predictible, sorry having sollicited the list. JM -Original Message- From: Victoria Reznichenko [mailto:[EMAIL PROTECTED]] Sent: Thursday, November 21, 2002 6:01 PM To: [EMAIL PROTECTED] Subject: r

re: RE : Duplicate key delete record with same key

2002-11-21 Thread Victoria Reznichenko
BPF, Thursday, November 21, 2002, 4:36:58 PM, you wrote: BW> CREATE TABLE `reg_member` ( BW> `account` bigint(20) NOT NULL auto_increment, BW> `userid` varchar(48) NOT NULL default 'Your name', BW> `uilogin` tinyint(4) NOT NULL default '0', BW> `id` varchar(48) NOT NULL default '', BW> `password`

RE : Duplicate key delete record with same key

2002-11-21 Thread BPF Webmaster
2002 3:31 PM To: BPF Webmaster; MySQL Subject: Re: Duplicate key delete record with same key Hi, Could you give us SHOW CREATE TABLE your_table ? Greetings from France too ;) Jocelyn - Original Message - From: "BPF Webmaster" <[EMAIL PROTECTED]> To: "MySQL" <

Re: Duplicate key delete record with same key

2002-11-21 Thread Jocelyn Fournier
Hi, Could you give us SHOW CREATE TABLE your_table ? Greetings from France too ;) Jocelyn - Original Message - From: "BPF Webmaster" <[EMAIL PROTECTED]> To: "MySQL" <[EMAIL PROTECTED]> Sent: Thursday, November 21, 2002 2:25 PM Subject: Duplicate

Duplicate key delete record with same key

2002-11-21 Thread BPF Webmaster
Using PHP 4.2.3 with MySQL 3.23.52 Report: --- - Table has 2 keys: 'account' as PRIMARY and 'id' as unique - I make an SQL update on an existing a record with id="anid" setting id="anotherid" but another record exists with id ="anotherid" - The update is performed and the record already existi