Tip - SQL Server Management Studio - Duplicate Tab
[SQL Server, SQL Server Management Studio, Tips]
Suppose you have this query:
SELECT
Countries.CountryID,
Countries.Name,
Countries.Code,
Countries.EditUserID,
Countries.DateModified,
Countries.CreateUserID,
Countries.DateCreated,
Countries.Approved,
Countries.ApprovedUserID,
Countries.DateApproved
FROM
dbo.Countries;
You want to duplicate it and make some adjustments and then run a second, different version.
The obvious way to do it is as follows:
- Select all the text (Ctrl + A)
- Create a new tab (Ctrl + N)
- Switch to the new tab
- Paste the text (Ctrl + V)
- Make any necessary modifications
- Run
Alternatively, you can right-click the title of the tab and from the menu that displays, choose Duplicate Tab
Happy hacking!