Monday, June 24, 2013

Adding and Subtracting from Date Field

ZP SQL handles dates differently than ZP 32. In ZP SQL all dates are stored in a long DATETIME format that includes both date information and time information. In ZP 32 all dates were stored a simple DATE format. If you want to perform calculations with dates in your ZP SQL reports or documents, you sometimes will need to convert the long DATETIME format to a simpler DATE format first. This is done with the function TTOD( ) - which stands for "Timestamp to Date." So if I want to add 30 days to the Violation Date my report expression would be: TTOD(vio_date) + 30.

No comments:

Post a Comment