@echo off set Datum=%date:~6,4%-%date:~3,2%-%date:~0,2% echo %DATUM% pause