BusinessObjects Board

how to sysdate() in universe

Hi,

Can u help me.

How to use sysdate() in universe for one object


BONEW (BOB member since 2004-09-03)

yes, create an object and in the select field, enter sysdate() function


bernard timbal :fr: (BOB member since 2003-05-26)

no luck.

getting error


BONEW (BOB member since 2004-09-03)

You will get error since there is no table associated with it.
IF you are going to use it with other universe objects to create a query then dont bother about the error.
Else use dual table to display its value in designer

.


haider :es: (BOB member since 2005-07-18)

i tried.

step 1.

to_char(tran_date,‘YYYY’) = to_char(sysdate,'YYYY)

it asking from keyword not found.

step 2.

to_char(tran_date,‘YYYY’) = to_char(sysdate,'YYYY) from dual - getting error


BONEW (BOB member since 2004-09-03)

Hi,
Are you trying to get the year data for tran_date?
then create one condition in the unvierse as
to_char(tran_date,‘YYYY’)=(select to_char(sysdate,‘YYYY’)from dual)
this will give you tran_dates’s data for the current year.

Hope this helps you out.


Omkar Paranjpe :us: (BOB member since 2006-02-13)

same error

from keyword error. ( when i am parsing)


BONEW (BOB member since 2004-09-03)

Hi,
There was one error in my syntax, now try again.


Omkar Paranjpe :us: (BOB member since 2006-02-13)

to_char(tran_date,'YYYY') = to_char(sysdate,'YYYY) 

If you are using this in the object definition it will not work, is it a condition object which you want to create.
Also put the missing quotes on the right of the expression or is it typo.

.


haider :es: (BOB member since 2005-07-18)

yes, i coreeted it. but still same error

to_char(tran_date,‘YYYY’)=(select to_char(sysdate,‘YYYY’) from dual)


BONEW (BOB member since 2004-09-03)

Hi,
In my post itself i said create on condition.
Yes, inititally there was a single quote missing.
But I corrected it later on.


Omkar Paranjpe :us: (BOB member since 2006-02-13)

I tried in where cluse also.

getting Invalid definition error.


BONEW (BOB member since 2004-09-03)

Hi,
Did you try to create a condition object or in a dimension object?


Omkar Paranjpe :us: (BOB member since 2006-02-13)

thanks lot , thanku vey much.

its working fine. now.

if possible pls help me to find previous qtr .+

pls guide me & where i cant get pre qtr sql


BONEW (BOB member since 2004-09-03)

Moderator note:
Bonew, please do not use Instant Message abbreviations on BOB. We want to keep BOB easy to understand for our International community. Thanks.


Andreas :de: (BOB member since 2002-06-20)

There is a very nice FAQ entry about using sysdate for date objects.

You have already asked about the previous quarter in another topic; please do not start another discussion here, but use the original topic. Thanks.

Closing topic.


Dave Rathbun :us: (BOB member since 2002-06-06)