Home » SQL & PL/SQL » SQL & PL/SQL » Query to get Status of Students as 'Pass' or 'Fail' Using Date Condition (Oracle 11g)
Query to get Status of Students as 'Pass' or 'Fail' Using Date Condition [message #607817] Wed, 12 February 2014 05:02 Go to next message
sonudev
Messages: 18
Registered: November 2009
Location: bangalore
Junior Member
Hi,

I need to find the list of students as 'Pass' or 'Fail' for a particular year. Then how to write a query using one date condition, lets say a year like 2013 from a list of years.
Suppose I have the data like:

name year status
XX 2010 Pass
XY 2011 Fail
XZ 2013 Pass
XD 2011 Pass
XF 2013 Pass
XC 2010 Fail
XB 2010 Pass

My requirement is:

Name Year Status
..... .... .....
XZ 2013 Pass
XF 2013 Pass
XY 2011 Fail
XD 2011 Pass
XX 2010 Pass
XC 2010 Fail
XB 2010 Pass




Re: Query to get Status of Students as 'Pass' or 'Fail' Using Date Condition [message #607818 is a reply to message #607817] Wed, 12 February 2014 05:11 Go to previous messageGo to next message
Littlefoot
Messages: 19521
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
I don't see any difference (except sort order). So, what does "using one date condition" mean? I'm afraid I don't understand it.
Re: Query to get Status of Students as 'Pass' or 'Fail' Using Date Condition [message #607819 is a reply to message #607817] Wed, 12 February 2014 05:14 Go to previous messageGo to next message
John Watson
Messages: 4514
Registered: January 2010
Location: Global Village
Senior Member
This is a college homework question? If you show what SQL you have tried so far, and what problems you have with it, and then someone can advise.
Re: Query to get Status of Students as 'Pass' or 'Fail' Using Date Condition [message #608225 is a reply to message #607819] Mon, 17 February 2014 13:42 Go to previous message
sonudev
Messages: 18
Registered: November 2009
Location: bangalore
Junior Member
John! actually, I asked because I just didn't get it properly on first thought. But anyway I have got my hints. Thanks to all of you.
Previous Topic: ORDER BY the day of the week
Next Topic: EMAIL from ORACLE8i using Corporate Netwrok
Goto Forum:
  


Current Time: Thu Aug 28 20:34:42 CDT 2014

Total time taken to generate the page: 0.19946 seconds