--If all arguments are NULL, COALESCE returns NULL. COALESCE(expression1,...n) --is equivalent to this CASE function: CASE WHEN (expression1 IS NOT NULL) THEN expression1 --... WHEN (expressionN IS NOT NULL) THEN expressionN ELSE NULL
Never been to CodeSnippets before?
Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world (or not, you can keep them private!)
Simple COALESCE example (See related posts)
You need to create an account or log in to post comments to this site.
Related Posts
» Randomly ordered results in ... in sql tsql
» Dynamic ordering without dyn... in sql tsql
» find duplicates in sql tsql
» Simple TSQL cursor in tsql
» Replace text in a TEXT type ... in tsql
» Retrieve MSSQL table informa... in sql server tsql mssql table microsoft column information properties sysproperties systables data type types length columns
Snippets (source code soon to be available) developed by Peter Cooper and powered by Ruby On Rails