Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2020 : Report Design
Message Icon Topic: Help: previous month name Post Reply Post New Topic
Author Message
Nav522
Senior Member
Senior Member


Joined: 25 Aug 2009
Location: United States
Online Status: Offline
Posts: 166
Quote Nav522 Replybullet Topic: Help: previous month name
    Posted: 20 Nov 2009 at 11:09am
Hello Folks,
                    I am trying to retrieve the name of the previous month. I was able to get the current month name like this "

to_char(sysdate,'FMMon YYYY')

" but finding it hard to get the previous one. Does anybodyy hav any idea about this one.
 
 
Thanks     
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 20 Nov 2009 at 11:45am
MonthName(month(dateadd('m',-1,currentdate)))
IP IP Logged
Nav522
Senior Member
Senior Member


Joined: 25 Aug 2009
Location: United States
Online Status: Offline
Posts: 166
Quote Nav522 Replybullet Posted: 20 Nov 2009 at 11:52am
hey thanks for getting back. It returns with MonthName as Invalid Identifier. Any idea about why its happening.
 
 
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 20 Nov 2009 at 11:55am
Are you using this a s crystal synatx formula and what version of crystal are you using?
IP IP Logged
Nav522
Senior Member
Senior Member


Joined: 25 Aug 2009
Location: United States
Online Status: Offline
Posts: 166
Quote Nav522 Replybullet Posted: 20 Nov 2009 at 12:05pm

well am creating a report using the sql query through the Command option. I shud pull the previous monthname for the report and we are using BOXIR2 and the server is Oracle server.

 
 
Thanks
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 20 Nov 2009 at 12:16pm
My formula was for a crystal syntax formula.
Not sure for Oracle.
 
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.047 seconds.