Hi! Just wondering how uniqueness works in a query, which I think is pretty standard in SQL?
I want to Query All Records and if there's a bunch of results that are the same, trim the fat and only get distinct records. The "Distinct Records" option would seem to solve this issue, but it does not work for me. Saw some other folks who are not sure what it does / if it properly does the job.
My case is I'm trying to query all users who have posted. So I have an inner join bw User and Post table. There are many more posts than users, so the return (without any additional WHERE clause - maybe that's the thing I should focus on?) value includes a bunch of repeated user values.
My current stop-gap solution is to use "unique" after the queried array is returned, but then my pagination is wack on frontend. I'm getting 7-10 records, instead of the uniform 12 my frontend expects.
Anyway... SUMMARY: HOW DO YOU ENSURE RECORDS ARE UNIQUE IN QUERY ALL? SPECIFICALLY IN A JOIN, FOR EXAMPLE?
Thanks so much!