Hello all,
Really appreciate any help on this issue.
My reports are giving output on GMT based off the server machine configuration. I need to create a variable at the report level to covert the time to PST
for eg. if its sep 8, 2010 05:20:00 PM i want the create a variable to convert this to PST and show it as Sep 8, 2010 10:20:00 AM (-7 hrs).
Or need some help to make a object at the universe itself.
thanks for reply Billu,
Our database is Oracle 10G. Have a question
tz_offset( timezone )
so for timezone should i give the time zone that i need like in my case it is PST. But what about the timestamp column and how does this work without pointing to any column?
FROM_TZ( timestamp_value, time_zone_value )
In here timestamp is the column that has GMT time while time_zone is the “PST” right?
You are right. You should supply timezone code corresponding to PST which you can get by running the query
SELECT tzname, tzabbrev FROM V$TIMEZONE_NAMES where upper(tzabbrev)='PST'
In the universe you can create an object without pointing to any column. Though it would show error on validation,it wont give you any error while running the report as it would be used along with other objects which are taken from database fields.
Alternatively you can insert oracle view sys.DUAL in to the universe and link to that table(Click the ‘Table Button’ object defnition tab).
from_tz function converts a TIMESTAMP value (given a TIME ZONE) to a TIMESTAMP WITH TIME ZONE value.
If you executed the following SQL statement:
select from_tz(TIMESTAMP '2005-09-11 01:50:42', '5:00')
from dual;
You would now get the following result:
11-Sep-05 01.50.42.000000 AM +05:00
So this function does not satisfy your requirement i guess…
So this function does not satisfy your requirement i guess…
first of all thanks for you reply again and clarify certain things, these are definitely very good suggestions which i will be using at the database level.
But yah i am looking for a solution at the report level.
Creating tz_offset( timezone ) in universe and using that at report level should work for your requiremnt .
FROM_TZ( timestamp_value, time_zone_value ) is not a solution for this as its different functionality.
If you want to resolve it at the report level,we need to try something else.
One doubt , if its always GMT/PST offset ,then why cant we create a formula which subtracts the offset(Ofsset value can be hardcode if it is always GMT to PST) from date field.
Hello gurus, i am still having problem with this rek. I am not able to find a syntax that would help me resolve the issue. I need to resolve this on the same field that holds all the time values.
Problem again “All the predefined audit reports (crystal reports) are showing the timestamp on GMT time. The rek is to keep all the existing format on the reports but have them display the proper time which is PST in our case. So any help is very much appreciated”
BOXI 3.1 sp2
backend Oracle 10g
field that has time stamp : start_timestamp
table name: Audit_event.