I am also facing same problem for if use token 'A-DBN'. In this case i get this in output
Current database name is [SQLSTATE 01000]
but, surprisingly other tokens like MACH & SRVR are working. I tested this on SQL 2012 (11.0.3000.0)
Kind Regards,
Chintak Chhapia