Share via


Whats this dollar sign next to my database name in my query?

Question

Monday, April 11, 2016 5:40 PM

Hi All,

What's the meaning of the dollar sign in this query?  I just found it in some stored procedures.

SELECT * FROM [$(myDatabase)]..CustomersTable

Thanks for your help.

-Eric B.

All replies (2)

Monday, April 11, 2016 5:51 PM ✅Answered | 1 vote

Hello eric,

have you found it in a live database or in a SSDT = SQL Server Data Tools project? In the last it is a variable for the database name, for which the project is for.

Olaf Helper

[ Blog] [ Xing] [ MVP]


Monday, April 11, 2016 6:11 PM

Yes, it is in a stored procedure, but that procedure isn't in my report project.  It's almost surely part of another SSDT project, though.  It seems strange that the deployed stored procedure has this in it.

Thanks for your help, Olaf.