Please tell me, how to use Aggregator stage to find the maximum value in a time stamp filed.
When I tried using that field for calculation ( max value), it was throwing an error that 'Invalid conversion from timestamp to dfloat'
Is it wheather Aggregator stage does not support calculation( Eg. Max value) on fileds which are Timestamp datatype?
Aggreator Stage - to find max values of a timestamp field
Moderators: chulett, rschirm, roy
Explicitly convert your timestamp into a numeric format using SecondsSinceFromTimestamp and some starting timestamp and then use the aggregator to get the maximum. You can then reconvert this back to a timestamp format after the aggregation.
<a href=http://www.worldcommunitygrid.org/team/ ... TZ9H4CGVP1 target="WCGWin">
</a>
</a>
-
- Premium Member
- Posts: 209
- Joined: Fri Jan 09, 2004 1:14 pm
- Location: Toronto, Canada
- Contact:
This is a little surreal; I just now needed to do the same thing, and got the same error.
Thanks, Arnd, for your idea.
I had only a date, not a date time, so I converted to an integer using:
and went back again using:
Of course, now I have a bunch of other errors to contend with, but this one has gone away
Rob
Thanks, Arnd, for your idea.
I had only a date, not a date time, so I converted to an integer using:
Code: Select all
DaysSinceFromDate("1900-01-01",From_DB.SNAP_DT)
Code: Select all
DateFromDaysSince(To_DB.SNAP_DT,"1900-01-01")
Rob
Rob Wierdsma
Toronto, Canada
bartonbishop.com
Toronto, Canada
bartonbishop.com
-
- Premium Member
- Posts: 209
- Joined: Fri Jan 09, 2004 1:14 pm
- Location: Toronto, Canada
- Contact:
I'm starting to come to the realization that I cannot perform any aggregations on non-numeric columns in the aggregator stage
Is this true
I'm trying to do a vertical pivot. Many of my columns are numeric and I can get the surviving value by doing a Max, however, aggregator is choking on all the character columns that I apply a Max to.
Rob
Is this true
I'm trying to do a vertical pivot. Many of my columns are numeric and I can get the surviving value by doing a Max, however, aggregator is choking on all the character columns that I apply a Max to.
Rob
Rob Wierdsma
Toronto, Canada
bartonbishop.com
Toronto, Canada
bartonbishop.com
-
- Participant
- Posts: 407
- Joined: Mon Jun 27, 2005 8:54 am
- Location: Walker, Michigan
- Contact:
-
- Participant
- Posts: 407
- Joined: Mon Jun 27, 2005 8:54 am
- Location: Walker, Michigan
- Contact: