Hi Experts
I am trying to create a SQL statement using the group option but find it behaves similar to that of the "Distinct" option. It is eliminating the matching or grouped records.
The Deal:
fields: phone, name
I want to be able to sort on name but group by phone
SELECT ALL * FROM testsort GROUP BY phone ORDER BY name
I have 1079 records to start, after the SQL runs I have 854 (Where the rest go?)
My hope was to have an alphabetical listing of names except where the different names have the same phone number then I would have hoped they would have been "GROUPED" together by the phone number.
Is this doable with the SQL or do I need to create a separate sort field and force common data into it before sorting.
Thanks in advance,
Rich
I am trying to create a SQL statement using the group option but find it behaves similar to that of the "Distinct" option. It is eliminating the matching or grouped records.
The Deal:
fields: phone, name
I want to be able to sort on name but group by phone
SELECT ALL * FROM testsort GROUP BY phone ORDER BY name
I have 1079 records to start, after the SQL runs I have 854 (Where the rest go?)
My hope was to have an alphabetical listing of names except where the different names have the same phone number then I would have hoped they would have been "GROUPED" together by the phone number.
Is this doable with the SQL or do I need to create a separate sort field and force common data into it before sorting.
Thanks in advance,
Rich