SHARE
TWEET

Untitled

a guest Aug 20th, 2019 48 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. CREATE FUNCTION IsSumEqualToTen
  2. (
  3.     @number1 INT,
  4.     @number2 INT
  5. )
  6. RETURNS BIT
  7. AS
  8. BEGIN
  9.     RETURN
  10.     (
  11.         WITH AddNumbers AS
  12.         (
  13.             SELECT @number1 + @number2
  14.         )
  15.         SELECT CASE WHEN AddNumbers = 10
  16.         THEN 1
  17.         ELSE 0
  18.         END
  19.     )
  20. END
  21.      
  22. CREATE FUNCTION IsSumEqualToTen
  23. (
  24.     @number1 INT,
  25.     @number2 INT
  26. )
  27. RETURNS BIT
  28. AS
  29. BEGIN
  30.     RETURN
  31.     (
  32.         CASE WHEN (@number1 + @number2) = 10
  33.         THEN 1
  34.         ELSE 0
  35.         END
  36.     )
  37. END
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top