My Assistant Formula

SUGGESTED

Similar to below but I only want to return invoices where the month and year do not match.  The day of the month doesn't matter.  I'm sure it's a formula but I don't know how to "join" the month and year together in a formula for comparison.

  • 0
    SUGGESTED

    Hi   ,

    Thank you for reaching out. Did you ever find an answer for this issue?  Checked in with the Sage 300 CRE support team regarding the following.

    To compare only the month and year in your Sage 300 Construction and Real Estate formula, you'll need to extract these two parts from the dates and compare them separately. You can use the MONTH() and YEAR() functions for this purpose.

    For instance, if you want to return invoices where the accounting date and invoice date do not have the same month and year, your formula might look something like this:

    IF NOT (MONTH([AP_MASTER__INVOICE].”Accounting_Date”) = MONTH([AP_MASTER__INVOICE].”Invoice_Date”) AND YEAR([AP_MASTER__INVOICE].”Accounting_Date”) = YEAR([AP_MASTER__INVOICE].”Invoice_Date”))
    

    This formula checks if the month and year of the accounting date and the invoice date do not match, and it returns true if they don't.

    Please make sure to replace [AP_MASTER__INVOICE].”Accounting_Date” and [AP_MASTER__INVOICE].”Invoice_Date” with the actual fields used in your database.

    If you need more assistance or if you're encountering any issues with creating or modifying formulas, don't hesitate to get in touch with Sage customer support, or check out the extensive formula documentation available on the Sage Knowledgebase. It's also a good practice to back up your User.frm file regularly, as it contains your custom formulas.

    Let us know if there’s anything else we can help with!

    Warm Regards,
    Erzsi