Le 21/10/2020 à 22:56, Stéphane Santon a écrit :
SELECT "a"."nom", "a"."date_absence", "b"."lastdate"
FROM "absencesCsv3" "a"
INNER JOIN (
SELECT "nom", MAX( "date_absence" ) "lastdate"
FROM "absencesCsv3"
GROUP BY "nom" ) "b"
ON "a"."nom" = "b"."nom"
ORDER BY "nom", "date_absence"
Mais le champ lastdate du MAX reste vide comme pour le COUNT...
Si je ne fais rien que :
SELECT nom, MAX(date_absence) lastdate from absencesCsv3 GROUP BY nom
Probablement parce que ma table est du texte issu de CSV et non une
vraie table HSQLDB...
Exact, chez moi, avec une base HSQLDB interne ça donne le bon résultat.
Mais il faut que la date soit au format Date, sinon le résultat est faux.
Bonne soirée
--
Jean-Michel Coste
--
Envoyez un mail à users+unsubscribe@fr.libreoffice.org pour vous désinscrire
Les archives de la liste sont disponibles à https://listarchives.libreoffice.org/fr/users/
Privacy Policy: https://www.documentfoundation.org/privacy
Context
Privacy Policy |
Impressum (Legal Info) |
Copyright information: Unless otherwise specified, all text and images
on this website are licensed under the
Creative Commons Attribution-Share Alike 3.0 License.
This does not include the source code of LibreOffice, which is
licensed under the Mozilla Public License (
MPLv2).
"LibreOffice" and "The Document Foundation" are
registered trademarks of their corresponding registered owners or are
in actual use as trademarks in one or more countries. Their respective
logos and icons are also subject to international copyright laws. Use
thereof is explained in our
trademark policy.