How to find how many sundays in a year

Hi friends...
how to find the how many sundays in a year?
can u give me the query?

Sybrand's approach can still be made to work. His formula actually calculates the number of weeks between the first and last Sunday of the year, so he needs to add one to get the number of Sundays (or calculate the number of weeks between to the first sunday of the following year). It also needs a tweak to deal with cases when the year starts or ends on a Sunday because next_day will return the following Sunday.
with t as (
select add_months(trunc(sysdate,'YEAR'),12*(level-20)) as yr from dual connect by level <= 40
select extract(YEAR from yr) as yr,
(next_day(add_months(yr, 12)-1,'SUN')
next_day(yr-1, 'SUN'))/7 as sundays
from t
order by yr
YR                     SUNDAYS
1991                   52
1992                   52
1993                   52
1994                   52
1995                   53
1996                   52
1997                   52
1998                   52
1999                   52
2000                   53
2001                   52
2002                   52
2003                   52
2004                   52
2005                   52
2006                   53
2007                   52
2008                   52
2009                   52
2010                   52
2011                   52
2012                   53
2013                   52
2014                   52
2015                   52
2016                   52
2017                   53
2018                   52
2019                   52
2020                   52
2021                   52
2022                   52
2023                   53
2024                   52
2025                   52
2026                   52
2027                   52
2028                   53
2029                   52
2030                   52Regards,
Bob

Similar Messages

  • I am an MBA student , doing a research project on e-learning authoring tools, would like to find out no. of licences sold/active to date for adobe captivate. how many get sold every year. any pointers/help is appreciated. cheers.

    I am an MBA student , doing a research project on e-learning authoring tools, would like to find out no. of licences sold/active to date for adobe captivate. how many get sold every year. any pointers/help is appreciated. cheers.

    I doubt you'll get an answer in a user forum, sorry. This forum is meant for users to help other users when they have problems that have to be solved. You should contact Adobe itself.

  • Fm - how many weeks in a year

    is there any FM for
    how many weeks in a year and
    how to find the whether the year is leap year or not? and
    how many weeks are in the month ?
    i want the FM

    Hi Priya,
    There is a function module 'TIME_GET_LAST_WEEK'.
    In this FM, export the Year & you will get(Import) a value in a parameter
    EF_WEEK. This will be the Concatenated String of Year&Number_of_weeks in that year
    For Example If you run this FM for the Year 2004, the Parameter EF_WEEK will
    be '200453'. That means last two digits gives the number of weeks in that year.
    From this value you can easily get number of weeks (i.e,EF_WEEK+4(2)).
    If this value is 53, then it is a leap year, else not a leap year
    Regards,
    Sreenivas Reddy Maddi

  • How to check the query, which had run how many times in a year?

    <Moderator Message: ok, subject is better now but you didn't search at all. Therefore thread is locked again>
    Hi All,
    I want to check the Query statistics like it had run how many times in a year?
    Regards,
    Kiran
    Edited by: Siegfried Szameitat on Dec 9, 2008 11:55 AM

    Hi Kiran,
    please follow the below steps
    1. Create a query for that purpose
    2. Make use of BW Statistic InfoProvider 0BWTC_C02
    3. in Col: Key Figure:0TCTNAVCTR
    4. in Row: 0TCTQUERY (select a variable 0TCTQUYS)
    5. in Filter: BW System( 0TCTSYSID) [give yr source system name whether its production/quality)
    6. in Free char you can give calmonth/year  or user if want to do so.
    save and execute the query
    you will be asked for input the query name
    As output you will be getting count (as many times query is hit by all users since the time it was created)
    if you give date and user name then it will display the count accordingly.
    Hope it Clarifies you.
    Thanks & Regards
    Nagaraju.V

  • To find that one user has done how many Transaction during the year

    Guru,
    Could u suggest which table to check to find transaction done during the year by a user.
    I have to develop report with some changes now o/p is needed as one user in whole year how many TC done and list those.
    regards,
    Vibhuti

    Hi
    goto CDHDR and enter username and dates and
    it will list all the transcation for the year
    Regards
    Shiva

  • Find  HOW MANY Saturdays IN A YEAR

    Dear Experts,
    I have to display the number of SATURSDAYS in a  YEAR .
    How I can do it ?
    Thanks in advance.
    Moderator message: date calculation questions = FAQ, please search before posting.
    locked by: Thomas Zloch on Sep 8, 2010 12:00 PM

    Hi,
    Just try the below given code by giving year as input.
    PARAMETERS:p_year(4) type n.
    data: date type d,
          ndate type d,
          rem type i,
          count type i.
      date+0(4) = p_year.
      date+4(2) = 01.
      date+6(2) = 01.
      rem = p_year mod 4.
      if rem eq 0.
      ndate = date + 366.
      else.
        ndate = date + 365.
       endif.
       clear rem.
       while date+0(4) eq p_year.
         move date to rem.
         rem = rem - 1.
         rem = rem mod 7.
         if rem eq 6.
           count = count + 1.
           ENDIF.
         date = date + 1.
       ENDWHILE.
    write:/ 'N.o of saturdays are ',count.
    It is helpful.

  • How do I find out how many files I have, as an earlier version of iTunes told you at the bottom of the screen. Can you please help me.

    How do I find out how many files I have, as an earlier version of iTunes told you at the bottom of the screen.
    Can anyone please help me with this so I know how many music files or video files I have in my collection.

    Have a look here...
    http://osxdaily.com/2012/11/29/5-tips-make-itunes-look-normal/

  • Is there a way of finding out how many active hours you've worked on a Premiere project?

    If not, it'd be a very cool addition for Adobe to implement... so you know exactly how many hours a project is taking (and how much to charge clients etc.) Obviously we're all prone to leaving Premiere on and wandering away, so I guess it would need to be able to differentiate between active and non-active time...

    Is there a way of finding out how many active hours you've worked on a Premiere project?
    There are two things a client get's billed for, my time, and my computer's time.  If either one of us are working on a project, the client get's billed.  Even if Adobe spent (wasted?) time on adding such a feature, they'd never be able to include any time I've spent working on the project with PP closed, so this feature would have very, very, VERY limited usefulness.
    The method suggested by the images is still the best way.

  • How do I view what slide I'm on out of how many I have total in keynote? I know on powerpoint it's at the bottom right of the window but I can't find it on keynote nor can I find the option to make it appear. Any help would be greatly appreciated.

    How do I view what slide I'm on out of how many I have total in keynote? I know on powerpoint it's at the bottom right of the window but I can't find it on keynote, nor can I find the option to make it appear. Any help would be greatly appreciated.

    Your steps so far are OK but you may want to try:
    1 Trash your user library Caches folder (House Icon with short name in Finder window (hard drive window)GOTO:House icon > Library folder > caches folder
    2 Trash the com.apple.Safari.plist file in User library > preferences folder > Safari.plist as well as removing the library Safari folder its self.
    3 you can selectivly re-install Safari 2.0 from your OS Tiger Install disk 1, (see Knowledge base article 301229 for how to just select the Safari Application) without doing a complete system Archive and Install.
    4. Create a new Test user account on the system and test how Safari responds in the Test user, see if its a user related issue and not system issue.
    5. Still no Safari response? have to do an Archive and install (not preserving user and network settings)article 107120
    PS. Issue may be related to actual internet connection connectivity, power cycle cable modem and router or airport if using one as well as the computer(keep unplugged for 3-5 min) and plug the cable modem in and then the router/airport then power on the computer. Do the Airport Admin utiliy (applications, utilities on HD_1)update.
    - do a hard reset of airport knowledge base article 108044(Express base) and 107451 (Extreme base)
    - Check with internet provider for connection issues "cannot find server" ect.

  • Am I able to find out how many times my ICloud account has been accessed?

    Am I able to find out how many times my ICloud account has been accessed?

    I'm afraid iCloud doesn't provide access logs.

  • Finding query access frequency or how many times a query has been executed?

    Dear Experts
    I need to find the total number of access frequency of individual queries that are requested by the users say at a particular time.
    Say there are 20 distinct queries requested in the time difference of 3 hours. All of the 20 queries or some of the queries may be requested for more than 2/3 times at that time by other users. By the way say query Q1 is requested 5 times at that so its query access frequency or how many times this query is executed is 5.
    From where and how can I can find this counting of query access frequency or how many times a query has been executed at particular time or a session?
    Normally we know the there SQL history dynamic performance views or if it can be possible to query the Shared pool library cache for SQL area it may be possible to find the total number of execution time for a query. But how to find that if anyone knows, please help me about this.
    Regards-
    Engr. A.N.M. Bazlur Rashid
    OCP DBA

    That's one of the stats reported by statspack - assuming that your query does sufficient work to meet the thresholds for the standard report. Executions is of course one of the columns of v$sql so you might just wish to sample that yourself. Finally if you are on 11g and the sql you are interested is relatively low resource intensive and you are licensed for AWR then you can use the slightly madly named "colored sql" feature that ensures that a specific statement will always be sampled for AWR.
    Niall Litchfield
    http://www.orawin.info/

  • How to find how many times a program has been executed & by whom

    Can any one help me to find log of program : Details like how many times the program(T-Code) has been executed and by whom(User ID) and when

    Hi,
    sy-uname will give u the name of the person.
    sy-uzeit will give u the time of exection.
    Not sure about number of times of execution.
    <REMOVED BY MODERATOR>
    regards,
    Ramya
    Edited by: Alvaro Tejada Galindo on Mar 19, 2008 4:15 PM

  • How to find how many times a t code has been processed by a user

    How to find how many times a t code has been processed by a user I am not able to get the exact number from the ST03 or STAD/STAT transaction. I am requiring the specific number that this T code has been processed completely this many no of times for a specific period.

    You must be more precise with your question.
    How long is the time period which you want to check, few hours or several days or longer? And how many executions do you expect, 100, 10000 or millions?
    The STAD should help you, for the smaller numbers. There is no solution for the larger ones. Don't mix STAD and ST03, ST03 is aggregated STAD information
    and know only how often a transaction was executed in total.
    ST05 is no solution for your problem to much overhead, and yoou should trace only a short period.
    There is no tool to check usage of transactions in more detail because of privacy reasons.
    Siegfried

  • How to find out how many memory is used for NIO

    is there any way to find out how many memory is used for nio in a virtual machine. ?
    I know that is possible to find out how many total, free and used memory the heap has by using java.lang.Runtime#totalMemory...
    We sometimes expect errors that it is not possible to create any more connections because of the NIO memory size but the heap is still ok. Today we had an error where 170mbytes of heap where left but it was not possible to create new tcp connections because of an exception:
    javax.naming.NamingException: java.net.SocketException: No buffer space available (maximum connections reached?): connect
    The number of TCP-Connections was ok (<500).
    It would be very nice if someone knows how to find out how the amount of memory that NIO buffers use can be determined within Java 1.4.
    best regards
    benjamin

    We have to use 1.4.2_03. This is because of the special environment we are running on.
    We did also figured out that there are some NIO Memory Bugs but we since we are not allowed to upgrade the used Virtual Machine we have to live with these errors.
    The problem that we currently have is within a Server and because of this circumstance we are trying to find a workaround or way to find out how many memory is allocated. If we would know how to get this value we could restart the servers as a workaround after the value reaches a threshold.
    We are also very sad that we can`t easily upgrade/update to the latest 1.4.2 Version or the newest 1.5 to get rid of these NIO Bugs!

  • Need to find out how many users are using Siebel Application

    Hello all,
    I need to find out how many users are using Siebel Application?
    Is there a way I can find out?
    Thanks.
    yasun

    Hi,
    Read the following:
    http://docs.oracle.com/cd/B40099_02/books/SysDiag/SysDiagSysMonitor30.html
    http://docs.oracle.com/cd/B40099_02/books/SysDiag/SysDiagSysMonitor17.html
    For full information about server status and statistics red:
    http://docs.oracle.com/cd/B40099_02/books/SysDiag/SysDiagSysMonitor.html
    T.Abed

Maybe you are looking for