Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I have a table in a mapinfo .tab file. Is there any way to select distinct values from the column?

I tried :-

SELECT distinct (some_column) from table_name into temp_table

But this query would select all values. I wanted to select only distinct value from that column. Is there any way to achieve it?

share|improve this question
add comment

2 Answers 2

up vote 7 down vote accepted

MapInfo Pro does not support the Distinct keywork, unfortunately. However you can get to the same result just be grouping your result by the column

Select some_column from table_name into temp_table Group By some_column
share|improve this answer
add comment

It appears if you simply group by column name, the results only come up once ( as per a distinct) Just tested in MapInfo 10.0

share|improve this answer
    
Welcome to our site! Could you perhaps provide an explicit example of what the command looks like and the output it would give for a simple dataset? –  whuber Oct 19 '12 at 13:56
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.