Solved

CASE WHEN NOT 0 then Calculate else dont calculate

Posted on 2012-03-13
2
277 Views
Last Modified: 2012-08-13
trying to calculate a Payment_Filter field but some syntax occur,

logic : when tmems.fsrvmembsamt is not 0 then calculate, else dont calculate or set payment filter to 0

(CASE WHEN tmems.fSrvMemBSAmt <> 0 THEN
(tmems.fSrvMemBSAmt - tmems.fSrvMemPacAmt) as Payment_Filter
ELSE
Payment_Filter = 0
END)
0
Comment
Question by:doramail05
  • 2
2 Comments
 
LVL 1

Accepted Solution

by:
doramail05 earned 0 total points
ID: 37718128
got it already

Payment_Filter = (CASE WHEN tmems.fSrvMemBSAmt <> 0 THEN
(tmems.fSrvMemBSAmt - tmems.fSrvMemPacAmt)
ELSE
0
END)
0
 
LVL 1

Author Closing Comment

by:doramail05
ID: 37718146
solved oredi
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
In this article we will learn how to fix  “Cannot install SQL Server 2014 Service Pack 2: Unable to install windows installer msi file” error ?
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
Using examples as well as descriptions, and references to Books Online, show the documentation available for datatypes, explain the available data types and show how data can be passed into and out of variables.

808 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question