Yahoo Poland Wyszukiwanie w Internecie

Search results

  1. 26 lip 2013 · I'm trying to do an IF statement type function in SQL server. Where there is a NULL in the field, I want it to take a field from one of the tables and add 10 days to it. And if possible create another column and add the 30 days.

  2. 15 mar 2013 · In SQL Server 2017, Microsoft introduced a Concatenate With Separator function, for just your situation: SELECT CONCAT_WS(' ', first_name, last_name) FROM dbo.person CONCAT_WS skips NULL values, but not empty strings.

  3. How do you check for NULL in a CASE statement, when you're using a Scalar Function? My original query was ... but it fails. SELECT CASE dbo.fnCarerResponse ('') WHEN NULL THEN 'Pass' ELSE 'Fail' END. I read the SO question about using IS NULL, like so ... SELECT CASE dbo.fnCarerResponse ('') IS NULL WHEN NULL THEN 'Pass' ELSE 'Fail' END.

  4. 3 wrz 2024 · CASE can be used in any statement or clause that allows a valid expression. For example, you can use CASE in statements such as SELECT, UPDATE, DELETE and SET, and in clauses such as <select_list>, IN, WHERE, ORDER BY, and HAVING. Transact-SQL syntax conventions.

  5. 11 lip 2012 · Is there any better way to write the lines below in SQL Server 2005? CASE WHEN (ID IS NULL) THEN 'YES' WHEN (ID IS NOT NULL) THEN 'NO' END AS ID_Value,

  6. 1 sie 2017 · I have a WHERE clause that I want to use a CASE expression in. However, my CASE expression needs to check if a field IS NULL. If the @UserRole variable value = 'Analyst', then the SupervisorApprovedBy column value must be NULL. Otherwise, I am saying return all data i.e. SupervisorApprovedBy = SupervisorApprovedBy.

  7. The CASEexpression goes through conditions and returns a value when the first condition is met (like an if-then-else statement). So, once a condition is true, it will stop reading and return the result. If no conditions are true, it returns the value in the ELSEclause.

  1. Ludzie szukają również