I have a table in my sql that have names and cities for example.
I want to make a Select Command that get all the cities and remove from the result the duplicates.
for the select i am using:
string citiesSelect = "SELECT [city] FROM [people] ORDER BY [city]";
CitiesDataSource.SelectCommand = citiesSelect;
CitiesDataSource.Select(DataSourceSelectArguments.Empty);
DropDownList2.DataSourceID = CitiesDataSource.ID;