Coalesce sql server7/9/2023 WHEN job_desc = 'Chief Financial Officier' THEN '400K' WHEN job_desc = 'Business Operations Manager' THEN '350K' WHEN job_desc = 'Chief Executive Officer' THEN '500K' WHEN job_desc = 'New Hire - Job Not Specified' THEN '25K' The following query: SELECT job_desc, salary_level = Syntax for this flavor of CASE is as follows: SELECT column_name = CASEįor instance, suppose that we want to specify the salary level for each jobĬategory within my publishing company. Replace occurrences of one value with other values, as specified by the Perhaps the most commonly used function, which is classified as a systemįunction, is CASE. Microsoft SQL Server 2000 DBA Survival Guide, 2nd Edition
0 Comments
Leave a Reply. |