Kbase 17452: Actuate - Date Solution
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  10/05/1998 |
|
Actuate - Date Solution
Overcoming the Date Issue In Actuate
The GetDate() Function in Actuate is a bit Confusing.
The WorkAround For getDate() Function is Date() and Date$().
These functions return current Date.
The Dates are handled differently in Actuate for Progress.
It appears that the date function does not run from the Query Builder
but one solution is to overide the ObtainSelectStatement() by changing
the WhereClause. The WhereClause is a string which Actuate appends
to the SQL at run time.
So any calculation or expression can be directly modified by
writing the WhereClause.
eg: The report Gives order information till yesterday
Function ObtainSelectStatement( ) As String
Dim ld_date As String
ld_date = Format(Now(), "mm,dd,yyyy")
WhereClause = " Order.Promise-Date < date (" & ld_date & ")"
ObtainSelectStatement = Super::ObtainSelectStatement( )
' Insert your code here
End Function
OR
If One has an Existing condition in the QueryBuilder the
Above code has to be modified to:
Function ObtainSelectStatement( ) As String
Dim ld_date As String
ld_date = Format(Now(), "mm,dd,yyyy")
WhereClause = WhereClause &
" AND Order.Promise-Date < date (" & ld_date & ")"
ObtainSelectStatement = Super::ObtainSelectStatement( )
' Insert your code here
End Function
The function ObtainSelectStatement() is Avaialable in the DataStream
Progress Software Technical Support Note # 17452