Copy link to clipboard
Copied
Hi
have a mysql databse which includes colums: UserSex, UserEthnicity,UserAge, UserArea etc.
I've created a form using spry select to search the database for any combination or age, sex ethnicity etc.
When I add four test records to the database and then run the search page in the drop down box I see (for example) Male female,male female so it's listing the entry for every record.
A google search told me that in the record set I had to use SELECT DISTINCT
so I edited the record set as below
SELECT UserEthnicity, UserAge, UserTypes, UserArea
FROM users
But this hasn't stopped the duplicates.
Is this coding correct?
thanks
Ian
Copy link to clipboard
Copied
Sorry pasted the wrong code
SELECT DISTINCT UserEthnicity, UserAge, UserTypes, UserArea
FROM users
Ian