Tag: Tables

  • SQL Managemnet Studio (SSMS)- Retrieve Unsaved Scripts

    While working with SQL Server Management Studio (SSMS), we can have crash issues. This causes loss of our scripts / queries / query windows data. Sometimes we get “Not responding” error message and restarted again after automatically closed. We can’t stop this. This will be frustrating to re-write all statements again. So, there are some…

  • Search in MSSQL tables

    Sometime we need to reverse engineering in the database tables to find a specific values, we can find the column name easily but in large database, to search a specific key value is too hard. From below query we can easily search value in all tables, it will list column with table in the result.…

  • Get rows count of the tables – Microsoft SQL Server

    [sql] CREATE TABLE #counts ( table_name varchar(255), row_count int ) EXEC sp_MSForEachTable @command1=’INSERT #counts (table_name, row_count) SELECT ”?”, COUNT(*) FROM ?’ SELECT table_name, row_count FROM #counts ORDER BY table_name, row_count DESC DROP TABLE #counts [/sql]

  • How to export schema of MYSQL Database?

    If you need schema of your MYSQL database for backup or any copy database to another server, then you must need schema with or without data. GUI tools like SQLYog, WebYog or PHPmyAdmin will best example for that. But if you need any command or utility then MYSQLDUMP has most important role. For using mysqldump…