Explanation:
sys.databases contains information about all databases on the SQL Server instance.
• HAS_DBACCESS(name) = 1 filters out the databases you dont have access to.
•ORDER BY name sorts the result alphabetically.
Rathi, 2025-03-04
Explanation:
sys.databases contains information about all databases on the SQL Server instance.
• HAS_DBACCESS(name) = 1 filters out the databases you dont have access to.
•ORDER BY name sorts the result alphabetically.
SELECT name FROM sys.databases WHERE HAS_DBACCESS(name) = 1 ORDER BY name;
You rated this post out of 5. Change rating
This week we have a few back to the basics security comments from Steve.
2019-06-25
421 reads
A company has both a server without a password and live data in test environments. Not a good situation.
2019-05-07
361 reads
2019-04-29
721 reads
2019-04-22
1,044 reads
Last year I started to get alerts from Microsoft Repos that someone had put a piece of security information in their code that pertained to one of my Azure services. At first I was worried, but then I realized this was the public version of AdventureWorks we maintain in Azure. We've published the login so […]
2019-04-17
193 reads
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy