Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Crystal Reports - ShiftDateTime Function

Status
Not open for further replies.

shuber1

IS-IT--Management
Jan 29, 2010
8
US
In Crystal Reports 2008, what inputs should I use in the ShiftDateTime function to convert India time to CST?
 
DateAdd allows you to add or subtract hours from a DateTime field

[yinyang] Madawc Williams (East Anglia, UK). Using Crystal 11.5 with SQL and Windows XP [yinyang]
 
Can you please provide more information? How would the DateAdd formula look?
 
DateAdd has the format
Code:
DateAdd ("m", 1, {your.date})
"Add" includes subtract, which would be -1, -42 or whatever. There are a choice of time periods, with year-ends and leap-years allowed for. The value returned is a date-time and time intervals can also be used.

Choices are yyyy, Year. q, Quarter (3-month period). m, Month. y, Day of year. d, Day. w, Weekday. ww, Week (7-day period). Months are whole calendar months.

Your 'HELP' function should give you this.

[yinyang] Madawc Williams (East Anglia, UK). Using Crystal 11.5 with SQL and Windows XP [yinyang]
 
Thank you for your reply.

Do you know what inputs should I use in the DateAdd function to convert India time to CST?
 
Use "h", for hour, however many hours it is.

You should have a 'HELP' function that will let you look it up for yourself.

[yinyang] Madawc Williams (East Anglia, UK). Using Crystal 11.5 with SQL and Windows XP [yinyang]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top