Siegfried,
you will need to calculate the Date Difference in days divided by 365 as
shown in the following example:
*select Cast({d '2019-05-04'} - {d '2019-03-12'} AS DECIMAL) /365 from
dual;*
Cheers
Andreas
On Tuesday, September 29, 2020 at 4:21:33 PM UTC+7 [email protected] wrote:
> Hello
> I export data from an H2 database and save it in a CSV.
> That's going well.
> I would like to save the age in another column.
> Age = current date - Date of birth (GEBURTSDATUM)
>
> Is that possible.
>
> CALL
> CSVWRITE('C:\Nextcloud-KCH\Vorstand\KC-Adressen\KC-Mitgliederadressen.csv',
> 'SELECT ANREDE,TITEL, NAME, VORNAME, STRASSE, PLZ, ORT, TELEFONPRIVAT,
> HANDY, EINTRITT, GEBURTSDATUM, EMAIL
> FROM PUBLIC.MITGLIED
> WHERE BEITRAGSGRUPPE IS NOT 56 ORDER BY NAME, VORNAME asc',
> 'charset=windows-1250 escape=" fieldDelimiter=" fieldSeparator=;
> writeColumnHeader=true');
>
> Siegfried
>
--
You received this message because you are subscribed to the Google Groups "H2
Database" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/h2-database/bf523f25-79de-477b-9915-70426ccea36bn%40googlegroups.com.