Results 1 to 3 of 3

Thread: weeknumber

  1. #1
    Join Date
    Oct 2002
    Posts
    1

    Post Unanswered: weeknumber

    How to get the weeknumber in a date in DB2
    with sql ?

  2. #2
    Join Date
    Jan 2002
    Location
    Manila, Philippines
    Posts
    71

    try ...

    WEEK (datecolumn)

    HTH,
    Oliver

  3. #3
    Join Date
    Oct 2002
    Posts
    11

    Re: weeknumber

    Hi,

    Use the column function Week

    WEEK
    >>-WEEK--(--expression--)--------------------------------------><


    The schema is SYSFUN.

    Returns the week of the year of the argument as an integer value in range 1-54. The week starts with Sunday.

    The argument must be a date, timestamp, or a valid character string representation of a date or timestamp that is neither a CLOB nor a LONG VARCHAR.

    The result of the function is INTEGER. The result can be null; if the argument is null, the result is the null value.

    Regards

    Ashtyu

    Originally posted by guss
    How to get the weeknumber in a date in DB2
    with sql ?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •