0
I have this query in sql
SELECT
"Certificates"."Email",
"Organizations"."CommonName",
"Certificates"."Id",
"Certificates"."OrganizationId"
FROM
"Certificates"
INNER JOIN
"Organizations" ON "Organizations"."Id" = "Certificates"."OrganizationId"
ORDER BY
"Email"
LIMIT
15
OFFSET
0
However it returns me all the certificates, being that there are certificates with repeated emails, I wish it were only single emails, I tried to use DISTINCT after SELECT, but it keeps returning the same thing
In fact with this query it returns without repeated emails, but I am without the Id, and in my application I will use the Id too.
– Vinicius Macelai
And if possible at the time of comparing 2 different emails, he takes what has the largest Id
– Vinicius Macelai
Yes, I updated the answer.
– Jean Gustavo Prates
Sensational, thanks for the help
– Vinicius Macelai