Bug or No bug - Composite Unique Key using null values

2006-10-06 Thread Dan Julson
List, I have been mulling over this for a few days reading docs and going back and forth with people on this, so I figured I would come here before writing up a bug report. First of all, I have tested this on 4.1.18, 5.0.16, and 5.0.22 within Solaris 9 and Mandrake Linux LE 2005

Re: Deleting, skip the first n records

2006-10-04 Thread Dan Julson
You can add an offset in the Limit statement. Look at the Select Syntax in the docs. There is an even simpler solution to this problem. Use your creation field within a Where clause instead of using Order by and Limit. -Dan I'm trying to delete all but the newest n records. DELETE

Re: Deleting, skip the first n records

2006-10-04 Thread Dan Julson
, Dan Julson wrote: You can add an offset in the Limit statement. Look at the Select Syntax in the docs. There is an even simpler solution to this problem. Use your creation field within a Where clause instead of using Order by and Limit. -Dan I'm trying to delete all but the newest n

Re: Inserting/updating only when combo of fields is unique

2006-09-27 Thread Dan Julson
Brian, Look at the ON DUPLICATE KEY UPDATE syntax within the INSERT SYNTAX of the Docs. That should give you what you want. -Dan I have a need to insert a record only when the combination of 3 fields is unique. I do this by having an index with all 3 fields, and doing an INSERT IGNORE. This

Re: Query Question

2006-08-14 Thread Dan Julson
1234 1235 1236 or; select ID from T1 where ID = 1237 and ID1237 and ID 1237 LIMIT 3 I would want 1236 1238 I would be surprised if there was no way of doing this.but then again, I'm often surprised Thanks Michael -- Michael DePhillips www.star.bnl.gov -- Have a great day, Dan

Re: how to copt table not whole database

2006-01-17 Thread Dan Julson
Xiaobo, Using mysqldump, you can specify which tables to copy. The man for mysqldump is as such: mysqldump [options] [dbname [tablename]] Say db 'db' has tables x, y, and z in it. You only want to copy table x. mysqldump db x x.sql(or whatever you want to name it). Dan Thank you

Re: Query Help

2005-08-12 Thread Dan Julson
? -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED] -- Have a great day, Dan Julson Application Software Engineer API Outsourcing 1355 Mendota Heights Rd. Mendota Heights, MN 55120 651-675-2628 (work) 952-456-2067