Powershell Day 30
Day 30 Best Practice Having good Security is first best practice for any language no exception with Powershell. Having that...
2011-04-30
1,457 reads
Day 30 Best Practice Having good Security is first best practice for any language no exception with Powershell. Having that...
2011-04-30
1,457 reads
Day 29 Advance Security As discussed in earlier blog about “Security” Day 7. Continue on that we will discuss here...
2011-04-29
1,454 reads
Day 27 SQL Policy I highly recommand to go through the Policy –based management (BCM)’s official excellent site to learn...
2011-04-28
523 reads
Day 27 Inventory As discussed ealier about wmi, wmi is a good for accessing inventory data from remote system as:...
2011-04-27
533 reads
Day 26 Generate script Generate script for sql server objects is very simple, there are different ways we can generate...
2011-04-26
671 reads
Day 25 RMO I have observed that no body has written anything about RMO. And replications is one of my...
2011-04-25
397 reads
Day 24 Performance Monitor Sql Performance: ? performance counters sys.dm_os_performance_counters ? Top ten queries from sys.dm_exec_query_stats and sys.dm_exec_sql_text ? Processor: sys.dm_os_schedulers ?Memory : sys.dm_os_memory_clerks...
2011-04-24
893 reads
Day 23 SMO programming Part 4 AS we can work with Server, Database, Table, Column. You can get the similar...
2011-04-22
372 reads
Day 22 SMO programming Part 3 In earlier blog we have discussed about server and database classes, using table clase...
2011-04-22
522 reads
Day 21 SMO programming Part 2 Continue with my earlier blog where I discussed about the information about SMO. Today...
2011-04-21
503 reads
By Steve Jones
This is timely, as I’m currently on a boat in the Adriatic taking a...
You can find the slides and SQL scripts for my session “Spice up your...
By SQLPals
How to Clear the SSMS Cache (SSMS 21 and Later) Updated...
Comments posted to this topic are about the item Using CHOOSE()
Comments posted to this topic are about the item Re-Seeding a Broken Log Shipping...
Comments posted to this topic are about the item The DBA is Dead! Long...
We have this code that sets some status values and then queries them using the CHOOSE() function in SQL Server 2025.
CREATE TABLE Status
(
StatusID INT,
StatusDescription VARCHAR(20)
);
GO
INSERT dbo.Status
(
StatusID,
StatusDescription
)
VALUES
(0, 'Uncategorized'),
(1, 'Active'),
(2, 'Inactive'),
(3, 'Temp');
GO
SELECT CHOOSE(StatusID, 'Unknown', 'Active', 'Inactive', 'Temporary')
FROM Status;
When the SELECT runs, what is returned? See possible answers