Skip to Content
author's profile photo Former Member
Former Member

Date format in webi

Hi Experts

I am unable to change my current date format that is in 10/12/2010 into 10th December 2010 in webi . Pls help me to solve this.

One more thing is that in one of the pdfs i could come across the following

DayNumberOfYear

Description : Returns the number of the day in the year in a date

Syntax:integer DayNumberOfYear(date input_date)

Output

The number of the day in the year

Example

DayNumberOfYear([Reservation Date]) returns 349 when the date in

[Reservation Date] is 15 December 2001

My question is

What is this reservation date?

For the whole Date and time function he used this reservation date as the object.I couldnt follow this..

Try to explain it with an example.. i mean the procedure that i need to follow in order to get this.?

Thank you

Regards

sharath

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Dec 10, 2010 at 03:46 PM

    You should use a formula in a variable to get your desired format. I am going to assume you have an object in your universe called Date or

    [Date]

    as it will appear when used in a Webi formula. To get the date format:

    = substr([Date];0;2) & Month([Date]) & substr([Date];6;11)

    Also, the code to return the number of the day in the year:

    = DayNumberOfYear([Date])

    The example was using

    [Reservation Date]

    as an example of a Date type object in Webi. It could equally have been

    [Posting Date]

    .

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Dec 12, 2010 at 05:59 PM

    Hi Sharath,

    To answer the date format query, let me assume that you have an object

    [Date]

    of type Date.

    In WebI, you can use the formula

     =FormatDate([Date];"ddth Mmm yyyy") 

    to get the desired date format.

    If the object is of type Character and retuns the date in format dd/MM/yyyy, then you have to convert it into a date before using FormatDate function. In this case you can use the formula

    =FormatDate(ToDate([Date];"dd/MM/yyyy");"ddth Mmm yyyy") 

    The function DayNumberOfYear takes a parameter of type date and returns the no of days elapsed till that date since the beginning of that year.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.