I recently saw that when I issue
select DB_NAME(0)
there is some answer, and when I check sys.databases there is no DB ID 0, so I think there should be a NULL return. If I select DB_NAME(1000) and there is no db id 1000 the return is NULL.
I noticed that the database I'm currently using is always displayed.
Is this normal? is this a bug or something?