noob query

noob query

am 16.12.2006 22:04:17 von grant

I'd like to write a simple select query. In a particular 1000-row db I
have one column (field) where many of the rows (records) have the same
entry. I'd like to write a query that returns all the different entries
in that column, but each one only once.

Re: noob query

am 16.12.2006 22:09:56 von Shion

grant wrote:
> I'd like to write a simple select query. In a particular 1000-row db I
> have one column (field) where many of the rows (records) have the same
> entry. I'd like to write a query that returns all the different entries
> in that column, but each one only once.

Use DISTINCT

example: SELECT DISTINCT field FROM mytable


--

//Aho

Re: noob query

am 19.12.2006 20:34:30 von unknown

Post removed (X-No-Archive: yes)