Introduction In this blog post, will see how can we easily find or search Table, View and Stored Procedure, Function names in SQL Server. SQL Script for Sample Table, View, SP, Function Creation -- Sample Table Creation CREATE TABLE TestTable ( TestTable_key INT IDENTITY(1,1) NOT NULL, TestTable_Name VARCHAR(100) NOT NULL ); GO -- Sample View… Continue reading Easy Like Search to find Table, View, Stored Procedure and Function Names in SQL Server
Month: February 2020
ON and OFF IntelliSense within Session in SSMS
Introduction In this blog post, we will see how to Switch ON or OFF IntelliSense within Session Level in SSMS (SQL Server Management Studio). Refresh, Enable and Disable IntelliSense Feature in SSMS (SQL Server Management Studio) works commonly for all sessions. But here, we will see how to Enable or Disable IntelliSense within Session level in… Continue reading ON and OFF IntelliSense within Session in SSMS
SQL Question and Answer #2
Everything we see is a perspective, not the truth. Question Pic Question SQL Script SELECT $42; SELECT $ 42; SELECT $ 42; SELECT $ 42; Q & A Will Line 1 Query Run without any error? If 'Yes', what's the Result? If 'No', Why it throws error? Keep Guess.... The Answer is Yes, Line 1… Continue reading SQL Question and Answer #2
Import CSV and TXT Files as Tables in SQL Server
Introduction In this blog post, we are going to look how can we import .csv and .txt files as tables in SQL Server and some of the possible errors to avoid in this process. Import .csv and .txt files as Tables in SQL Server .csv file ( Comma Delimited ) .csv file .txt file (… Continue reading Import CSV and TXT Files as Tables in SQL Server
Alternate to Interesting ISNUMERIC Function Results in SQL Server
Introduction In this blog post, we are going to see what is ISNUMERIC Function in SQL server and what are the interesting result sets that it gives for some inputs and what are the other alternatives that we can use instead of ISNUMERIC Function. ISNUMERIC Function in SQL Server The ISNUMERIC function in SQL Server… Continue reading Alternate to Interesting ISNUMERIC Function Results in SQL Server
Single Digit Special Characters used between SELECT and FROM in SQL Server
Introduction In this blog post, we are going to see what are the single digit special characters we can use between SELECT and FROM in SQL Server. Yup, many of us would guess and say '*' (Asterisk) . Yes, of course it's right and it will be our first answer. But What if my question… Continue reading Single Digit Special Characters used between SELECT and FROM in SQL Server
To Fetch Formatted Time from Date time in SQL Server
Introduction In this blog post, we will see How to format the time part from Date time in SQL Server. Here, we have mentioned some of the common and easy methods to achieve this. To Fetch Formatted Time from Date time Method 1 - CONVERT SQL Script SELECT GETDATE() AS INPUT, CONVERT(VARCHAR(5),GETDATE(),108) AS EXPECTED_OUTPUT; Image… Continue reading To Fetch Formatted Time from Date time in SQL Server
Truncate Extra Decimal Places to Exact Scale in SQL Server
Introduction In this blog post, we are going to see How we can Truncate Extra Decimal Places to Exact Scale in SQL Server. We can also say this as, Scale Only Round Off and Non-value Round Off. Method 1 - Using ROUND() SQL Script --Method 1 - Using ROUND() DECLARE @Test_Table AS TABLE (Test_Column DECIMAL(20,5));… Continue reading Truncate Extra Decimal Places to Exact Scale in SQL Server
SQL Question and Answer #1
Question Question Here, the User wants us to add the column name through stored procedure and if the given column name already exists, then we have to show the alert message instead of adding it. Answer We are going to use CREATE TABLE and DROP TABLE, EXEC SP_HELP, CREATE OR ALTER PROC, System View -… Continue reading SQL Question and Answer #1
To Copy and Sync Database Tables Across Different Server
Introduction In this blog post, we will see How to make Copy, Sync between database tables across different Server with simple steps. We can follow the below steps and can copy or sync our Database Tables across different server and same server with different databases. Scenario we need to sync one Database table named 'States'… Continue reading To Copy and Sync Database Tables Across Different Server