Truncate function???

B

bill yeager

Does anybody know if there is a similiar function in MS
Access like the ORACLE "TRUNCATE" function?

eg:

trunc(RSS_TRACKING.COMPLETION_DATE) AS COMPLETION_DATE

result is: 6/29/03

The truncate function basically will aggregate dates
(which I have in my GROUP BY clause) based off of a
common starting point, like every Sunday, for instance.

I tried using ROUND, but it seems only for numbers, not
dates. I also tried using the CONVERT and CAST functions
in addition to the ROUND function, but still couldn't do
the date conversion.

Thanks,

Bill.......
 
M

Merlin

I'm not familiar with Oracle and I'm not sure I understand your questions,
but in MS Access you can either create your own functions in code or use the
Format function:-
e.g replace the field name with an expression as in the following example;
this converts the date into Days (Monday - Sunday), which can then be
grouped in the normal manner. You can convert the date into any number of
different formats for sorting grouping.

Expr1: Format([RSS_TRACKING.COMPLETION_DATE],'dddd')

(use 'www' for week numbers or 'dddd www' for Day & week number) very useful
little function....

Merlin
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top