
sql server - How do you find the last time a database was accessed ...
Apr 2, 2009 · In SQL Server 2005, can you easily determine the last time someone queried a database.
sql server - How do I get list of all tables in a database using TSQL ...
Oct 6, 2008 · What is the best way to get the names of all of the tables in a specific database on SQL Server?
sql - Find out current database name (MSSQL) - Stack Overflow
Sep 15, 2022 · 6 With the MSSQL queries below, you can check the current database: SELECT DB_NAME() GO master In addition, if you don't specify a database on sqlcmd, "master" …
How to fix Recovery Pending State in SQL Server Database?
Sep 14, 2018 · One way to end up with a database that is in "Recovery Pending" state, is in the context of restoring a backup of an encrypted database (encrypted with TDE) on a new SQL …
SQL Server: how do I export entire database? - Stack Overflow
I need to export database from one server and import it into another server. How do I export the entire database to a file, or two files mdf, ldf (either option is fine) How do I import it into a new
sql - The transaction log for the database is full - Stack Overflow
SQL Server will autogrow the log during a transaction if it needs more space to complete that transaction.
python - How do I connect to SQL Server via sqlalchemy using …
70 sqlalchemy, a db connection module for Python, uses SQL Authentication (database-defined user accounts) by default. If you want to use your Windows (domain or local) credentials to …
How to Identify port number of SQL server - Stack Overflow
Oct 18, 2013 · Open SQL Server Management Studio Connect to the database engine for which you need the port number Run the below query against the database select distinct …
How do I see active SQL Server connections? - Stack Overflow
Aug 8, 2009 · I am using SQL Server 2008 Enterprise. I want to see any active SQL Server connections, and the related information of all the connections, like from which IP address, …
sql server - Script for rebuilding and reindexing the fragmented …
Can anyone provide the script for rebuilding and re-indexing the fragmented index when 'avg_fragmentation_in_percent' exceeds certain limits (better if cursor is not used)?