Solved

cognos formatting

Posted on 2013-01-18
3
406 Views
Last Modified: 2013-01-24
Hi,

I have an expression as below:

to_char(_first_of_month(_add_months(current_date,-6)))   and the output of it is  " 01-JUL-12"

but I need only "JULY". how to get this, please help.
0
Comment
Question by:new_perl_user
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 8

Assisted Solution

by:SNeupane
SNeupane earned 250 total points
ID: 38794236
All you have to do is add extract month in front of it.
For example:
extract(month from to_char(_first_of_month(_add_months(current_date,-6))) )
0
 
LVL 35

Accepted Solution

by:
Robert Schutt earned 250 total points
ID: 38794246
Have you tried
to_char(_first_of_month(_add_months(current_date,-6)), 'MONTH')

Open in new window

0
 
LVL 8

Expert Comment

by:SNeupane
ID: 38794248
Or use extract after the to_char like below.
It'll give you month in number:
to_char(extract(month from _first_of_month(_add_months(current_date,-6))))
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Crystal Report Link tables 5 242
Historical Data of SSRS Reports 1 90
SQL Report Builder Options 6 113
Jasper- i report - regarding sale order and order line report 1 94
Problem Statement In an SAP BI BO Integration project when a BO universe is built on a BEx query, there can be an issue of unit & formatted value objects not getting generated in a BO universe for some key figures. This results in an issue whereb…
Hi, In my previous Article  (http://www.experts-exchange.com/Database/Reporting/A_15199-Introduction-to-Microstrategy.html)I discussed some basic understanding of Microstrategy that how we can get in Intro of Microstrategy (MSTR). Now it's tim…
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…

738 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