Hi, Can someone please direct me to some documentation that shows how to do this ... ? I need to write a non-trivial function that will return a new custom (not in schema) field but which is more complicated than a simple sum/avg/etc. I want to create a function that looks at a few dateranges in the current records and return possible an enum or an integer ... Maybe something similar could also be helpful ... Thanks. SRK