Using the function

Using the function in QBE & SQL topic (part of our Corel Paradox / ObjectPAL Coding group).

Quick Search: function   Using function  
brationer1
Bridgetown, -- BB

Can "Today()" be used in a QBE or a Report? I am trying to use it in order to find the number of years an employee or a group of employees worked.

Something like: "(today() - Employee's Employment date)/ 365.25"

I can copy the data to a spreadsheet and get a result, but this not what I need. 

About brationer1
Visit Profile
Approved member.
Member subscribes to this thread with a verified email.

Post ID #14147, 3 replies
Thread Started 6/7/2010 6:39:43 AM
View Counter=4150
Last Reply Posted 6/11/2010 5:39:04 PM)
Location=Bridgetown, -- BB 
Joined=2/2/2010   MB Posts=17  
Moderator
Mike Prestwood
Prestwood IT
Prestwood IT office in Citrus Heights, CA

Yes, you sure can. In a QBE though, you don't use Today() with parens, but just Today.

As in...

>Today

for a date field after today.

--
Mike Prestwood
Prestwood IT Solutions

About Mike Prestwood
Visit Profile
Approved member.
Member subscribes to this thread with a verified email.
About Mike Prestwood

Mike Prestwood is a drummer, an author, and creator of the PrestwoodBoards online community. He is the President & CEO of Prestwood IT Solutions. Prestwood IT provides Coding, Website, and Computer Tech services. Mike has authored 6 computer books and over 1,200 articles. As a drummer, he maintains play-drums.com and has authored 3 drum books. If you have a project you wish to discuss with Mike, you can send him a private message through his PrestwoodBoards home page or call him 9AM to 4PM PST at 916-726-5675 x205.

Web Presence
Facebook, Prestwood IT Facebook page -- fan page. (Visit Me)
Twitter, Follow Prestwood IT on Twitter. (Visit Me)
LinkedIn, Prestwood IT company page on LinkedIn. (Visit Me)
YouTube, Prestwood IT YouTube Channel (Visit My Channel)
Website, My drum website where I sell my drum books. (http://www.play-drums.com)

Post ID #14151 (Level 1.1)  Reply to 14147
Thread Started 6/7/2010 11:48:14 AM
Location=Prestwood IT office in Citrus Heights, CA 
Joined=10/29/2000   MB Posts=1410   KB Posts=1805   KB Comments=53   BLOG, Topics=4  
brationer1
Bridgetown, -- BB

Thanks for your usual help Mike.  However, I need a little more light to achieve my objective.

I wouldn't mind using the QBE or a report, but I need to solve this.  I looked up a lot of ObjectPal for examples to no avail.

About brationer1
Visit Profile
Approved member.
Member subscribes to this thread with a verified email.

Post ID #14154 (Level 2.1)  Reply to 14151 and Parent is 14147
Thread Started 6/8/2010 6:58:02 AM
Location=Bridgetown, -- BB 
Joined=2/2/2010   MB Posts=17  
Most Recent Post
Moderator
Mike Prestwood
Prestwood IT
Prestwood IT office in Citrus Heights, CA

You can base a report off of a QBE file. When the report opens the report, it first runs the QBE then uses the answer table.

So, the first step is to create a QBE that generates an answer table with the correct data. Have you gotten that far? Do you have a QBE that shows the correct data?

After that, you can use ObjectPAL to pass in values to the QBE to tailor each run of the report.

--
Mike Prestwood
Prestwood IT Solutions

About Mike Prestwood
Visit Profile
Approved member.
Member subscribes to this thread with a verified email.
About Mike Prestwood

Mike Prestwood is a drummer, an author, and creator of the PrestwoodBoards online community. He is the President & CEO of Prestwood IT Solutions. Prestwood IT provides Coding, Website, and Computer Tech services. Mike has authored 6 computer books and over 1,200 articles. As a drummer, he maintains play-drums.com and has authored 3 drum books. If you have a project you wish to discuss with Mike, you can send him a private message through his PrestwoodBoards home page or call him 9AM to 4PM PST at 916-726-5675 x205.

Web Presence
Facebook, Prestwood IT Facebook page -- fan page. (Visit Me)
Twitter, Follow Prestwood IT on Twitter. (Visit Me)
LinkedIn, Prestwood IT company page on LinkedIn. (Visit Me)
YouTube, Prestwood IT YouTube Channel (Visit My Channel)
Website, My drum website where I sell my drum books. (http://www.play-drums.com)

Post ID #14166 (Level 3.1)  Reply to 14154 and Parent is 14147
Thread Started 6/11/2010 5:36:58 PM
Location=Prestwood IT office in Citrus Heights, CA 
Joined=10/29/2000   MB Posts=1410   KB Posts=1805   KB Comments=53   BLOG, Topics=4  
www.prestwood.com For service: 916-726-5675
or support@prestwood.com
Copyright (C) Prestwood IT Solutions.
All Rights Reserved.
Printed 6/14/2026