Skip to main content
ExLibris

Knowledge Assistant

BETA
  • Subscribe by RSS
  • Back
    Aleph

     

    Ex Libris Knowledge Center
    1. Search site
      Go back to previous article
      1. Sign in
        • Sign in
        • Forgot password
    1. Home
    2. Aleph
    3. Knowledge Articles
    4. Purging z31 cash transactions

    Purging z31 cash transactions

    1. Last updated
    2. Save as PDF
    3. Share
      1. Share
      2. Tweet
      3. Share
    1. Additional Information
    • Article Type: General
    • Product: Aleph
    • Product Version: 18.01

    Description:
    We want to delete old, paid cash transactions, but need to keep non-Lost transactions less than 6 months old and Lost transactions less than 2 years old.

    Could the p_cir_32 "scrub" job do this?

    Resolution:
    Unlike the z35, z36h, and z37h, from which the user ID might be removed and they would still have some use, z31s without a user ID are meaningless. Nevertheless, the p_cir_32 job, new in 16.02, does scrub the user_id from the z31 -- but it doesn't distinguish Lost from non-Lost transactions.

    The following SQL could be used to delete non-Lost paid (or waived or transferred*) transactions more than 6 months old:

    SQL>delete from z31 where Z31_DATE <= TO_CHAR(SYSDATE - 180, 'YYYYMMDD') and (Z31_STATUS = 'C' or Z31_STATUS = 'W' or Z31_STATUS = 'T') and (Z31_TYPE NOT in (40, 41, 42, 0040, 0041, 0042));

    And this to delete paid (or waived or transferred*) Lost transactions more than 2 years old:

    SQL>delete from z31 where Z31_DATE <= TO_CHAR(SYSDATE - 730, 'YYYYMMDD') and (Z31_STATUS = 'C' or Z31_STATUS = 'W' or Z31_STATUS = 'T') and (Z31_TYPE in (40, 41, 42, 0040, 0041, 0042));

    * T = Transactions transferred to the university Accounting office in cases where they do the money-handling. The p_cash_09 job does the export.

    **Note: Before doing either of these commands you need to back up the z31 table, using p_file_03.**

    Additional Information

    purge, Z31, cash transactions


    • Article last edited: 10/8/2013
    View article in the Exlibris Knowledge Center
    1. Back to top
      • Purging Cash History and return of old Lost items
      • Push records from one module to another with Windows 7
    • Was this article helpful?

    Recommended articles

    1. Article type
      Topic
      Language
      English
      Product
      Aleph
    2. Tags
      1. 18.01
      2. contype:kba
      3. Prod:Aleph
      4. Type:General
    1. © Copyright 2025 Ex Libris Knowledge Center
    2. Powered by CXone Expert ®
    • Term of Use
    • Privacy Policy
    • Contact Us
    2025 Ex Libris. All rights reserved