Solved

sql snytax

Posted on 2011-09-19
2
293 Views
Last Modified: 2012-06-27
case
                  when datePaid is not null then 'Paid'
                  else 'Not Paid'
            end as status    

I want to bring saying if my hold column shows true .. that time I want to say Hold between Paid and not paid... how would do that .. cant get the snytax correct...
0
Comment
Question by:1jaws
2 Comments
 
LVL 21

Accepted Solution

by:
JestersGrind earned 500 total points
ID: 36563286
CASE WHEN DatePaid IS NOT NULL THEN 'Paid'
          WHEN HoldColumn = 1 THEN 'Hold'
          ELSE 'Not Paid'
END AS Status

Is that what you are looking for?

Greg

0
 

Author Closing Comment

by:1jaws
ID: 36563303
thank you!!
0

Featured Post

Best Practices: Disaster Recovery Testing

Besides backup, any IT division should have a disaster recovery plan. You will find a few tips below relating to the development of such a plan and to what issues one should pay special attention in the course of backup planning.

Question has a verified solution.

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

Suggested Solutions

Naughty Me. While I was changing the database name from DB1 to DB_PROD1 (yep it's not real database name ^v^), I changed the database name and notified my application fellows that I did it. They turn on the application, and everything is working. A …
In this article we will get to know that how can we recover deleted data if it happens accidently. We really can recover deleted rows if we know the time when data is deleted by using the transaction log.
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…

756 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