Query to get the names of all tables in SQL Server 2008 Database

In a single database – yes:

USE your_database
SELECT name FROM sys.tables

Getting all tables across all databases – only with a hack…. see this SO question for several approaches how to do that: How do I list all tables in all databases in SQL Server in a single result set?

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)