Re: removing duplicates and giving average of other field.

2004-08-12 Thread Michael Stassen
Jeroen, One minor caveat here. You are grouping by gene_name, but selecting non-aggregate values from the chr and strand columns. Since they aren't part of the list of grouped columns, you'll get effectively randomly chosen values (probably the first found per group) for each from among the po

RE: removing duplicates and giving average of other field.

2004-08-11 Thread Lachlan Mulcahy
Hi Jeroen, Have you tried creating a new table by selecting the data that you want and then removing the old table and replacing it with the new one. Eg. CREATE TABLE new_g2d ( chr char(10) NOT NULL DEFAULT '', start int NOT NULL DEFAULT 0, stop int NOT NULL DEFA