{"text_format":"1","workbook":"xlsx","n_sheets":3,"sheets":["List Process","490000020","490000036"],"not_rendered":{"charts":0,"images":0,"macros":1,"external_links":0,"defined_names":0,"comments":0,"pivot_tables":0},"unopened":[],"bounds":{"document_bytes":16777216,"sheet_cells":100000,"rows_first":2000,"rows_last":500,"rows_between":2000,"halvings":0,"cell_chars":16384,"cell_head_chars":4096},"cells_cut":0,"cells_raw":0,"read":"whole","date_system":"1900"}

{"sheet":"List Process","index":0,"n_rows":3,"n_cols":2,"rows_kept":3,"cut":false,"hidden":false,"merged":[]}
["List Process"]
[490000020,"Accounts Receivable by Period"]
[490000036,"Accounts Receivable Historical"]

{"sheet":"490000020","index":1,"n_rows":102,"n_cols":7,"rows_kept":102,"cut":false,"hidden":false,"merged":[]}
["tableAlias","tableName","name","columnGroupHeading","columnHeading","calculation","Oncalculation"]
["UDM_AR_HIST","UDM_AR_HIST","COMPANYID","Company","ID"]
["UDM_DIMCOMPANY","UDM_DIMCOMPANY","COMPANYNAME","Company","Name"]
["UDM_DIMCOMPANY","UDM_DIMCOMPANY","LEDCUR","Ledger","Currency"]
["UDM_AR_HIST","UDM_AR_HIST","SITEID","Site","ID"]
["UDM_DIMSITES","UDM_DIMSITES","FCYNAM","Site","Name"]
["UDM_AR_HIST","UDM_AR_HIST","CUSTOMERID","Customer","ID"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","CLIENTNAME","Customer","Name"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","STATGROUP1","Customer Stat Group","Code 1"]
["UDM_DESCRIPTION","UDM_DESCRIPTION","DESCRIPTION","Customer Stat Group","Desc 1"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","STATGROUP2","Customer Stat Group","Code 2"]
["UDM_DESCRIPTION_1","UDM_DESCRIPTION","DESCRIPTION","Customer Stat Group","Desc 2"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","STATGROUP3","Customer Stat Group","Code 3"]
["UDM_DESCRIPTION_2","UDM_DESCRIPTION","DESCRIPTION","Customer Stat Group","Desc 3"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","STATGROUP4","Customer Stat Group","Code 4"]
["UDM_DESCRIPTION_3","UDM_DESCRIPTION","DESCRIPTION","Customer Stat Group","Desc 4"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","STATGROUP5","Customer Stat Group","Code 5"]
["UDM_DESCRIPTION_4","UDM_DESCRIPTION","DESCRIPTION","Customer Stat Group","Desc 5"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD01","Customer UDF 01","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD01DESC","Customer UDF 01","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD02","Customer UDF 02","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD02DESC","Customer UDF 02","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD03","Customer UDF 03","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD03DESC","Customer UDF 03","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD04","Customer UDF 04","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD04DESC","Customer UDF 04","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD05","Customer UDF 05","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD05DESC","Customer UDF 05","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD06","Customer UDF 06","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD06DESC","Customer UDF 06","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD07","Customer UDF 07","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD07DESC","Customer UDF 07","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD08","Customer UDF 08","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD08DESC","Customer UDF 08","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD09","Customer UDF 09","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD09DESC","Customer UDF 09","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD10","Customer UDF 10","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD10DESC","Customer UDF 10","Desc"]
["UDM_DIMADDRESS","UDM_DIMADDRESS","COUNTRY",null,"Country"]
["UDM_DIMADDRESS","UDM_DIMADDRESS","PROVINCESTATE",null,"State"]
["UDM_DIMADDRESS","UDM_DIMADDRESS","CITY",null,"City"]
["UDM_AR_HIST","UDM_AR_HIST","SALESPERID","Sales Representative","ID"]
["UDM_DIMSALESREP","UDM_DIMSALESREP","SALESREPNAME","Sales Representative","Name"]
["UDM_DIMSALESREP_1","UDM_DIMSALESREP","SALESREPNAME","Default Sales Representative","ID"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","DEFSALESREPID","Default Sales Representative","Name"]
["UDM_AR_HIST","UDM_AR_HIST","FISYEAR","Fiscal","Year"]
["UDM_AR_HIST","UDM_AR_HIST","FISPER","Fiscal","Period"]
["UDM_AR_HIST","UDM_AR_HIST","PERID","Fiscal","Period ID"]
["*SERVER","*SERVER","FLD00000023","Calendar","Year","BI_YEAR(:UDM_DIM_FISCALPERIOD.ENDDATE:)"]
["*SERVER","*SERVER","FLD00000030","Calendar","Period","BI_MONTH(:UDM_DIM_FISCALPERIOD.ENDDATE:)"]
["*SERVER","*SERVER","FLD00000031","Calendar","Period ID","BI_YEAR(:UDM_DIM_FISCALPERIOD.ENDDATE:) * 100 +\nBI_MONTH(:UDM_DIM_FISCALPERIOD.ENDDATE:)"]
["UDM_AR_HIST","UDM_AR_HIST","ACCOUNTID","Account","ID"]
["UDM_ACCOUNTS","UDM_ACCOUNTS","ACCOUNTDESC","Account","Description"]
["UDM_AR_HIST","UDM_AR_HIST","DOCNUM","Document","Number"]
["UDM_AR_HIST","UDM_AR_HIST","DOCTYP","Document","Type"]
["UDM_AR_HIST","UDM_AR_HIST","DOCDATE","Document","Date"]
["UDM_AR_HIST","UDM_AR_HIST","DUEDATE","Document","Due Date"]
["*SERVER","*SERVER","FLD00000013",null,"Aging Category","CASE\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) >= 0\nAND (BI_DATEDIFF(:[Document Due Date]:,:UDM_AR_HIST.PERLASTDATE:) <= 0\nOR UDM_AR_HIST.REMBALFLAG = 1)\nTHEN 'Current Amount'\n\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) < 0\nAND (BI_DATEDIFF(:[Document Due Date]:,:BI_GETDATE():) <= 0\nOR UDM_AR_HIST.REMBALFLAG = 1)\nTHEN 'Current Amount'\n\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) >= 0\nAND BI_DATEDIFF(:[Document Due Date]:,:UDM_AR_HIST.PERLASTDATE:) BETWEEN @@UDM_ARBUCKET01_MIN AND @@UDM_ARBUCKET01_MAX\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN '@@UDM_ARBUCKET01_MIN-@@UDM_ARBUCKET01_MAX Days'\n\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) < 0\nAND BI_DATEDIFF(:[Document Due Date]:,:BI_GETDATE():) BETWEEN @@UDM_ARBUCKET01_MIN AND @@UDM_ARBUCKET01_MAX\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN '@@UDM_ARBUCKET01_MIN-@@UDM_ARBUCKET01_MAX Days'\n\n\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) >= 0\nAND BI_DATEDIFF(:[Document Due Date]:,:UDM_AR_HIST.PERLASTDATE:) BETWEEN @@UDM_ARBUCKET02_MIN AND @@UDM_ARBUCKET02_MAX\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN '@@UDM_ARBUCKET02_MIN-@@UDM_ARBUCKET02_MAX Days'\n\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) < 0\nAND BI_DATEDIFF(:[Document Due Date]:,:BI_GETDATE():) BETWEEN @@UDM_ARBUCKET02_MIN AND @@UDM_ARBUCKET02_MAX\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN '@@UDM_ARBUCKET02_MIN-@@UDM_ARBUCKET02_MAX Days'\n\n\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) >= 0\nAND BI_DATEDIFF(:[Document Due Date]:,:UDM_AR_HIST.PERLASTDATE:) BETWEEN @@UDM_ARBUCKET03_MIN AND @@UDM_ARBUCKET03_MAX\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN '@@UDM_ARBUCKET03_MIN-@@UDM_ARBUCKET03_MAX Days'\n\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) < 0\nAND BI_DATEDIFF(:[Document Due Date]:,:BI_GETDATE():) BETWEEN @@UDM_ARBUCKET03_MIN AND @@UDM_ARBUCKET03_MAX\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN '@@UDM_ARBUCKET03_MIN-@@UDM_ARBUCKET03_MAX Days'\n\n\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) >= 0\nAND BI_DATEDIFF(:[Document Due Date]:,:UDM_AR_HIST.PERLASTDATE:) >= @@UDM_ARBUCKET04\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN '@@UDM_ARBUCKET04+ Days'\n\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) < 0\nAND BI_DATEDIFF(:[Document Due Date]:,:BI_GETDATE():) >= @@UDM_ARBUCKET04\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN '@@UDM_ARBUCKET04+ Days'\n\n\nEND"]
["*SERVER","*SERVER","FLD0000004",null,"Current Amount","CASE\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) >= 0\nAND (BI_DATEDIFF(:[Document Due Date]:,:UDM_AR_HIST.PERLASTDATE:) <= 0\nOR UDM_AR_HIST.REMBALFLAG = 1)\nTHEN [Amount Due]\n\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) < 0\nAND (BI_DATEDIFF(:[Document Due Date]:,:BI_GETDATE():) <= 0\nOR UDM_AR_HIST.REMBALFLAG = 1)\nTHEN [Amount Due]\n\nELSE 0\nEND"]
["*SERVER","*SERVER","FLD0000006","Overdue","@@UDM_ARBUCKET01_MIN-@@UDM_ARBUCKET01_MAX Days","CASE\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) >= 0\nAND BI_DATEDIFF(:[Document Due Date]:,:UDM_AR_HIST.PERLASTDATE:) BETWEEN @@UDM_ARBUCKET01_MIN AND @@UDM_ARBUCKET01_MAX\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN [Amount Due]\n\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) < 0\nAND BI_DATEDIFF(:[Document Due Date]:,:BI_GETDATE():) BETWEEN @@UDM_ARBUCKET01_MIN AND @@UDM_ARBUCKET01_MAX\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN [Amount Due]\n\nELSE 0\nEND"]
["*SERVER","*SERVER","FLD0000007","Overdue","@@UDM_ARBUCKET02_MIN-@@UDM_ARBUCKET02_MAX Days","CASE\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) >= 0\nAND BI_DATEDIFF(:[Document Due Date]:,:UDM_AR_HIST.PERLASTDATE:) BETWEEN @@UDM_ARBUCKET02_MIN AND @@UDM_ARBUCKET02_MAX\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN [Amount Due]\n\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) < 0\nAND BI_DATEDIFF(:[Document Due Date]:,:BI_GETDATE():) BETWEEN @@UDM_ARBUCKET02_MIN AND @@UDM_ARBUCKET02_MAX\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN [Amount Due]\n\nELSE 0\nEND"]
["*SERVER","*SERVER","FLD0000008","Overdue","@@UDM_ARBUCKET03_MIN-@@UDM_ARBUCKET03_MAX Days","CASE\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) >= 0\nAND BI_DATEDIFF(:[Document Due Date]:,:UDM_AR_HIST.PERLASTDATE:) BETWEEN @@UDM_ARBUCKET03_MIN AND @@UDM_ARBUCKET03_MAX\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN [Amount Due]\n\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) < 0\nAND BI_DATEDIFF(:[Document Due Date]:,:BI_GETDATE():) BETWEEN @@UDM_ARBUCKET03_MIN AND @@UDM_ARBUCKET03_MAX\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN [Amount Due]\n\nELSE 0\nEND"]
["*SERVER","*SERVER","FLD0000009","Overdue","@@UDM_ARBUCKET04+ Days","CASE\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) >= 0\nAND BI_DATEDIFF(:[Document Due Date]:,:UDM_AR_HIST.PERLASTDATE:) >= @@UDM_ARBUCKET04\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN [Amount Due]\n\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) < 0\nAND BI_DATEDIFF(:[Document Due Date]:,:BI_GETDATE():) >= @@UDM_ARBUCKET04\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN [Amount Due]\n\nELSE 0\nEND"]
["UDM_DIM_FISCALPERIOD","UDM_DIM_FISCALPERIOD","NUMBEROFDAYS","Month","Number of Days"]
["UDM_DIM_FISCALYEARROLL12","UDM_DIM_FISCALYEARROLL12","NUMBEROFDAYS","Year","Number of Days"]
["UDM_AR_HIST","UDM_AR_HIST","AMTDUEHC",null,"Amount Due"]
["*SERVER","*SERVER","FLD0000005",null,"Amount Overdue","CASE\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) >= 0\nAND BI_DATEDIFF(:[Document Due Date]:,:UDM_AR_HIST.PERLASTDATE:) > 0\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN [Amount Due]\n\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) < 0\nAND BI_DATEDIFF(:[Document Due Date]:,:BI_GETDATE():) > 0\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN [Amount Due]\n\nELSE 0\nEND"]
["UDM_AR_HIST","UDM_AR_HIST","CDTSALESAMT","Month","Credit Sales"]
["UDM_AR_HIST","UDM_AR_HIST","CDTSALESROLL12","Year","Credit Sales"]
["*SERVER","*SERVER","FLD0000001",null,"Overdue Ratio",0,"if([Amount Due] !== 0)\nnecResult = [Amount Overdue] / [Amount Due];\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000026","Overdue Ratio","@@UDM_ARBUCKET01_MIN-@@UDM_ARBUCKET01_MAX Days",0,"if([Amount Overdue] !== 0)\nnecResult = [Overdue @@UDM_ARBUCKET01_MIN-@@UDM_ARBUCKET01_MAX Days] / [Amount Overdue] ;\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000027","Overdue Ratio","@@UDM_ARBUCKET02_MIN-@@UDM_ARBUCKET02_MAX Days",0,"if([Amount Overdue] !== 0)\nnecResult = [Overdue @@UDM_ARBUCKET02_MIN-@@UDM_ARBUCKET02_MAX Days] / [Amount Overdue] ;\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000028","Overdue Ratio","@@UDM_ARBUCKET03_MIN-@@UDM_ARBUCKET03_MAX Days",0,"if([Amount Overdue]  !== 0)\nnecResult = [Overdue @@UDM_ARBUCKET03_MIN-@@UDM_ARBUCKET03_MAX Days] / [Amount Overdue] ;\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000029","Overdue Ratio","@@UDM_ARBUCKET04+ Days",0,"if([Amount Overdue] !== 0)\nnecResult = [Overdue @@UDM_ARBUCKET04+ Days] / [Amount Overdue] ;\nelse\nnecResult = 0;"]
["UDM_AR_HIST","UDM_AR_HIST","AMTDUEHCLM","Last Month","Amount Due"]
["UDM_AR_HIST","UDM_AR_HIST","AMTOVERDUELM","Last Month","Amount Overdue"]
["UDM_AR_HIST","UDM_AR_HIST","CDTSALESAMTLM","Last Month","Credit Sales"]
["*SERVER","*SERVER","FLD00000018","Last Month","Overdue Ratio",0,"if([Last Month Amount Due] !== 0)\n\nnecResult= ([Last Month Amount Overdue] / [Last Month Amount Due]);\n\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000016","M to M Growth","Amount Due",0,"if([Last Month Amount Due]!== 0)\n\nnecResult=([Amount Due] - [Last Month Amount Due]) / [Last Month Amount Due];\n\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000015","M to M Growth","Amount Overdue",0,"if([Last Month Amount Overdue] !== 0)\n\nnecResult=([Amount Overdue] - [Last Month Amount Overdue])/[Last Month Amount Overdue];\n\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000017","M to M Growth","Credit Sales",0,"if([Last Month Credit Sales] !== 0)\n\nnecResult=([Month Credit Sales] - [Last Month Credit Sales]) / [Last Month Credit Sales];\n\nelse\nnecResult = 0;"]
["UDM_AR_HIST","UDM_AR_HIST","AMTDUEHCLY","Last Year","Amount Due"]
["UDM_AR_HIST","UDM_AR_HIST","AMTOVERDUELY","Last Year","Amount Overdue"]
["UDM_AR_HIST","UDM_AR_HIST","CDTSALESAMTLY","Last Year","Credit Sales"]
["*SERVER","*SERVER","FLD00000019","Last Year","Overdue Ratio",0,"if([Last Year Amount Due] !== 0)\n\nnecResult= ([Last Year Amount Overdue] / [Last Year Amount Due]);\n\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000020","Y to Y Growth","Amount Due",0,"if([Last Year Amount Due]!== 0)\n\nnecResult=([Amount Due] - [Last Year Amount Due]) / [Last Year Amount Due];\n\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000021","Y to Y Growth","Amount Overdue",0,"if([Last Year Amount Overdue] !== 0)\n\nnecResult=([Amount Overdue] - [Last Year Amount Overdue])/[Last Year Amount Overdue];\n\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000022","Y to Y Growth","Credit Sales",0,"if([Last Year Credit Sales] !== 0)\n\nnecResult=([Month Credit Sales] - [Last Year Credit Sales]) / [Last Year Credit Sales];\n\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000024",null,"Document Count","CASE\nWHEN [Amount Due] <> 0\nTHEN 1\nELSE 0\nEND"]
["*SERVER","*SERVER","FLD00000025",null,"Average Days Overdue","CASE\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) >= 0\nAND BI_DATEDIFF(:[Document Due Date]:,:UDM_AR_HIST.PERLASTDATE:) > 0\nAND [Amount Due] <> 0\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN BI_DATEDIFF(:[Document Due Date]:,:UDM_AR_HIST.PERLASTDATE:)\n\nWHEN BI_DATEDIFF(:UDM_AR_HIST.PERLASTDATE:,:BI_GETDATE():) < 0\nAND BI_DATEDIFF(:[Document Due Date]:,:BI_GETDATE():) > 0\nAND [Amount Due] <> 0\nAND UDM_AR_HIST.REMBALFLAG = 0\nTHEN BI_DATEDIFF(:[Document Due Date]:,:BI_GETDATE():)\n\nEND"]
["*SERVER","*SERVER","FLD0000002","Month","Turn Over Ratio",0,"if (([Amount Due] + [Amount Due]LM) !== 0)\n\nnecResult= 2 * [Month Credit Sales] / ([Amount Due] + [Amount Due]LM);\n\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD0000003","Month","Collection Effective Index",0,"if (([Last Month Amount Due] + [Month Credit Sales] - [Current Amount]) !== 0)\nnecResult= ([Last Month Amount Due] + [Month Credit Sales] - [Amount Due]) / ([Last Month Amount Due] + [Month Credit Sales] - [Current Amount]) * 100;\n\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000010","Month","Real Days Sales Outstanding",0,"if([Month Credit Sales] !== 0)\nnecResult= [Amount Due] / [Month Credit Sales] * [Month Number of Days];\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000011","Month","Best Days Sales Outstanding",0,"if([Month Credit Sales] !== 0)\nnecResult= [Current Amount] / [Month Credit Sales] * [Month Number of Days];\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000012","Month","Average Days Delinquent",0,"if([Month Credit Sales] !== 0)\nnecResult= ([Amount Due] - [Current Amount]) / [Month Credit Sales] * [Month Number of Days];\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000014","Month","Average Collection Period",0,"if([Month Credit Sales] !== 0)\nnecResult= (([Amount Due] + [Amount Due]LM)/2) / [Month Credit Sales] * [Month Number of Days];\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000032","Year","Turn Over Ratio",0,"if (([Amount Due] + [Amount Due]LY) !== 0)\n\nnecResult= 2 * [Year Credit Sales]/ ([Amount Due] + [Amount Due]LY);\n\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000033","Year","Collection Effective Index",0,"if (([Last Year Amount Due] + [Year Credit Sales] - [Current Amount]) !== 0)\nnecResult= ([Last Year Amount Due] + [Year Credit Sales] - [Amount Due]) / ([Last Year Amount Due] + [Year Credit Sales] - [Current Amount]) * 100;\n\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000034","Year","Real Days Sales Outstanding",0,"if([Year Credit Sales]!== 0)\nnecResult= [Amount Due] / [Year Credit Sales] * [Year Number of Days];\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000035","Year","Best Days Sales Outstanding",0,"if([Year Credit Sales]!== 0)\nnecResult= [Current Amount] / [Year Credit Sales] * [Year Number of Days];\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000036","Year","Average Days Delinquent",0,"if([Year Credit Sales] !== 0)\nnecResult= ([Amount Due] - [Current Amount]) / [Year Credit Sales] * [Year Number of Days];\nelse\nnecResult = 0;"]
["*SERVER","*SERVER","FLD00000037","Year","Average Collection Period",0,"if([Year Credit Sales] !== 0)\nnecResult= (([Amount Due] + [Amount Due]LY)/2) / [Year Credit Sales] * [Year Number of Days];\nelse\nnecResult = 0;"]

{"sheet":"490000036","index":2,"n_rows":73,"n_cols":7,"rows_kept":73,"cut":false,"hidden":false,"merged":[]}
["tableAlias","tableName","name","columnGroupHeading","columnHeading","calculation","Oncalculation"]
["UDM_STGARHIST","UDM_STGARHIST","COMPANYID","Company","ID"]
["UDM_DIMCOMPANY","UDM_DIMCOMPANY","COMPANYNAME","Company","Name"]
["UDM_DIMCOMPANY","UDM_DIMCOMPANY","LEDCUR","Ledger","Currency"]
["UDM_STGARHIST","UDM_STGARHIST","SITEID","Site","ID"]
["UDM_DIMSITES","UDM_DIMSITES","FCYNAM","Site","Name"]
["UDM_STGARHIST","UDM_STGARHIST","CUSTID","Customer","ID"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","CLIENTNAME","Customer","Name"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","CREDITLIMT","Customer","Credit Limit"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","STATGROUP1","Customer Stat Group","Code 1"]
["UDM_DESCRIPTION","UDM_DESCRIPTION","DESCRIPTION","Customer Stat Group","Desc 1"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","STATGROUP2","Customer Stat Group","Code 2"]
["UDM_DESCRIPTION_1","UDM_DESCRIPTION","DESCRIPTION","Customer Stat Group","Desc 2"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","STATGROUP3","Customer Stat Group","Code 3"]
["UDM_DESCRIPTION_2","UDM_DESCRIPTION","DESCRIPTION","Customer Stat Group","Desc 3"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","STATGROUP4","Customer Stat Group","Code 4"]
["UDM_DESCRIPTION_3","UDM_DESCRIPTION","DESCRIPTION","Customer Stat Group","Desc 4"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","STATGROUP5","Customer Stat Group","Code 5"]
["UDM_DESCRIPTION_4","UDM_DESCRIPTION","DESCRIPTION","Customer Stat Group","Desc 5"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD01","Customer UDF 01","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD01DESC","Customer UDF 01","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD02","Customer UDF 02","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD02DESC","Customer UDF 02","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD03","Customer UDF 03","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD03DESC","Customer UDF 03","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD04","Customer UDF 04","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD04DESC","Customer UDF 04","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD05","Customer UDF 05","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD05DESC","Customer UDF 05","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD06","Customer UDF 06","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD06DESC","Customer UDF 06","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD07","Customer UDF 07","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD07DESC","Customer UDF 07","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD08","Customer UDF 08","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD08DESC","Customer UDF 08","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD09","Customer UDF 09","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD09DESC","Customer UDF 09","Desc"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD10","Customer UDF 10","Code"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","UDFIELD10DESC","Customer UDF 10","Desc"]
["UDM_DIMADDRESS","UDM_DIMADDRESS","COUNTRY",null,"Country"]
["UDM_DIMADDRESS","UDM_DIMADDRESS","PROVINCESTATE",null,"State"]
["UDM_DIMADDRESS","UDM_DIMADDRESS","CITY",null,"City"]
["UDM_STGARHIST","UDM_STGARHIST","SALESREPID","Sales Representative","ID"]
["UDM_DIMSALESREP","UDM_DIMSALESREP","SALESREPNAME","Sales Representative","Name"]
["UDM_DIMSALESREP_1","UDM_DIMSALESREP","SALESREPNAME","Default Sales Representative","ID"]
["UDM_DIMCLIENT","UDM_DIMCLIENT","DEFSALESREPID","Default Sales Representative","Name"]
["UDM_STGARHIST","UDM_STGARHIST","ACCOUNTID","Account","ID"]
["UDM_ACCOUNTS","UDM_ACCOUNTS","ACCOUNTDESC","Account","Description"]
["UDM_STGARHIST","UDM_STGARHIST","DOCNUM","Document","Number"]
["UDM_STGARHIST","UDM_STGARHIST","DOCTYP","Document","Type"]
["UDM_STGARHIST","UDM_STGARHIST","DOCDATE","Document","Date"]
["UDM_STGARHIST","UDM_STGARHIST","ORIDOCNUM","Adjusted Document","Number"]
["UDM_STGARHIST","UDM_STGARHIST","ORIDOCTYP","Adjusted Document","Type"]
["UDM_STGARHIST","UDM_STGARHIST","ORIDOCDATE","Adjusted Document","Date"]
["UDM_STGARHIST","UDM_STGARHIST","DUEDATE","Adjusted Document","Due Date"]
["*SERVER","*SERVER","FLD0000003",null,"Date Chosen","CASE\nWHEN [Company ID] = [Company ID]\nTHEN BI_TODATE(:'$$DATE','$$FORMAT':)\nEND"]
["*SERVER","*SERVER","FLD00000013",null,"Aging Category","CASE\nWHEN (BI_DATEDIFF(:[Adjusted Document Due Date]:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) <= 0\nOR UDM_STGARHIST.REMBALFLAG = 1)\nTHEN 'Current Amount'\n\nWHEN BI_DATEDIFF(:[Adjusted Document Due Date]:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) BETWEEN @@UDM_ARBUCKET01_MIN AND @@UDM_ARBUCKET01_MAX\nAND UDM_STGARHIST.REMBALFLAG = 0\nTHEN '@@UDM_ARBUCKET01_MIN-@@UDM_ARBUCKET01_MAX Days'\n\n\nWHEN BI_DATEDIFF(:[Adjusted Document Due Date]:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) BETWEEN @@UDM_ARBUCKET02_MIN AND @@UDM_ARBUCKET02_MAX\nAND UDM_STGARHIST.REMBALFLAG = 0\nTHEN '@@UDM_ARBUCKET02_MIN-@@UDM_ARBUCKET02_MAX Days'\n\n\nWHEN BI_DATEDIFF(:[Adjusted Document Due Date]:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) BETWEEN @@UDM_ARBUCKET03_MIN AND @@UDM_ARBUCKET03_MAX\nAND UDM_STGARHIST.REMBALFLAG = 0\nTHEN '@@UDM_ARBUCKET03_MIN-@@UDM_ARBUCKET03_MAX Days'\n\n\nWHEN BI_DATEDIFF(:[Adjusted Document Due Date]:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= @@UDM_ARBUCKET04\nAND UDM_STGARHIST.REMBALFLAG = 0\nTHEN '@@UDM_ARBUCKET04+ Days'\n\n\nEND"]
["*SERVER","*SERVER","FLD0000004","Ledger Currency","Current Amount","CASE\nWHEN (BI_DATEDIFF(:[Adjusted Document Due Date]:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) <= 0\nOR UDM_STGARHIST.REMBALFLAG = 1)\nTHEN UDM_STGARHIST.AMOUNTHC\n\n+\nCASE WHEN BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.EXCHRATEADJ ELSE 0 END\n\n+ \nCASE WHEN UDM_STGARHIST.HISTOTYPE = 2 AND BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.PAYAMTHC ELSE 0 END\n\nELSE 0\nEND"]
["*SERVER","*SERVER","FLD0000006","Overdue LC","@@UDM_ARBUCKET01_MIN-@@UDM_ARBUCKET01_MAX Days","CASE\nWHEN BI_DATEDIFF(:[Adjusted Document Due Date]:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) BETWEEN @@UDM_ARBUCKET01_MIN AND @@UDM_ARBUCKET01_MAX\nAND UDM_STGARHIST.REMBALFLAG = 0\nTHEN UDM_STGARHIST.AMOUNTHC\n\n+\nCASE WHEN BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.EXCHRATEADJ ELSE 0 END\n\n+ \nCASE WHEN UDM_STGARHIST.HISTOTYPE = 2 AND BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.PAYAMTHC ELSE 0 END\n\nELSE 0\nEND"]
["*SERVER","*SERVER","FLD0000007","Overdue LC","@@UDM_ARBUCKET02_MIN-@@UDM_ARBUCKET02_MAX Days","CASE\nWHEN BI_DATEDIFF(:[Adjusted Document Due Date]:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) BETWEEN @@UDM_ARBUCKET02_MIN AND @@UDM_ARBUCKET02_MAX\nAND UDM_STGARHIST.REMBALFLAG = 0\nTHEN UDM_STGARHIST.AMOUNTHC\n\n+\nCASE WHEN BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.EXCHRATEADJ ELSE 0 END\n\n+ \nCASE WHEN UDM_STGARHIST.HISTOTYPE = 2 AND BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.PAYAMTHC ELSE 0 END\n\nELSE 0\nEND"]
["*SERVER","*SERVER","FLD0000008","Overdue LC","@@UDM_ARBUCKET03_MIN-@@UDM_ARBUCKET03_MAX Days","CASE\nWHEN BI_DATEDIFF(:[Adjusted Document Due Date]:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) BETWEEN @@UDM_ARBUCKET03_MIN AND @@UDM_ARBUCKET03_MAX\nAND UDM_STGARHIST.REMBALFLAG = 0\nTHEN UDM_STGARHIST.AMOUNTHC\n\n+\nCASE WHEN BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.EXCHRATEADJ ELSE 0 END\n\n+ \nCASE WHEN UDM_STGARHIST.HISTOTYPE = 2 AND BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.PAYAMTHC ELSE 0 END\n\nELSE 0\nEND"]
["*SERVER","*SERVER","FLD0000009","Overdue LC","@@UDM_ARBUCKET04+ Days","CASE\nWHEN BI_DATEDIFF(:[Adjusted Document Due Date]:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= @@UDM_ARBUCKET04\nAND UDM_STGARHIST.REMBALFLAG = 0\nTHEN UDM_STGARHIST.AMOUNTHC\n\n+\nCASE WHEN BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.EXCHRATEADJ ELSE 0 END\n\n+ \nCASE WHEN UDM_STGARHIST.HISTOTYPE = 2 AND BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.PAYAMTHC ELSE 0 END\n\nELSE 0\nEND"]
["*SERVER","*SERVER","FLD0000002","Ledger Currency","Amount Due","UDM_STGARHIST.AMOUNTHC\n\n+\nCASE WHEN BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.EXCHRATEADJ ELSE 0 END\n\n+ \nCASE WHEN UDM_STGARHIST.HISTOTYPE = 2 AND BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.PAYAMTHC ELSE 0 END"]
["*SERVER","*SERVER","FLD0000005","Ledger Currency","Amount Overdue","CASE\nWHEN BI_DATEDIFF(:[Adjusted Document Due Date]:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) > 0\nAND UDM_STGARHIST.REMBALFLAG = 0\nTHEN UDM_STGARHIST.AMOUNTHC\n\n+\nCASE WHEN BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.EXCHRATEADJ ELSE 0 END\n\n+ \nCASE WHEN UDM_STGARHIST.HISTOTYPE = 2 AND BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.PAYAMTHC ELSE 0 END\n\nELSE 0\nEND"]
["*SERVER","*SERVER","FLD0000001",null,"Overdue Ratio",0,"if([Ledger Currency Amount Due] !== 0)\nnecResult = [Ledger Currency Amount Overdue] / [Ledger Currency Amount Due];\nelse\nnecResult = 0;"]
["UDM_STGARHIST","UDM_STGARHIST","TRANCUR","Transaction","Currency"]
["*SERVER","*SERVER","FLD00000010","Transaction Currency","Current Amount","CASE\nWHEN (BI_DATEDIFF(:[Adjusted Document Due Date]:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) <= 0\nOR UDM_STGARHIST.REMBALFLAG = 1)\nTHEN UDM_STGARHIST.AMOUNTTC\n\n+ \nCASE WHEN UDM_STGARHIST.HISTOTYPE = 2 AND BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.PAYAMTTC ELSE 0 END\n\nELSE 0\nEND"]
["*SERVER","*SERVER","FLD00000011","Overdue TC","@@UDM_ARBUCKET01_MIN-@@UDM_ARBUCKET01_MAX Days","CASE\nWHEN BI_DATEDIFF(:[Adjusted Document Due Date]:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) BETWEEN @@UDM_ARBUCKET01_MIN AND @@UDM_ARBUCKET01_MAX\nAND UDM_STGARHIST.REMBALFLAG = 0\nTHEN UDM_STGARHIST.AMOUNTTC\n\n+ \nCASE WHEN UDM_STGARHIST.HISTOTYPE = 2 AND BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.PAYAMTTC ELSE 0 END\n\nELSE 0\nEND"]
["*SERVER","*SERVER","FLD00000012","Overdue TC","@@UDM_ARBUCKET02_MIN-@@UDM_ARBUCKET02_MAX Days","CASE\nWHEN BI_DATEDIFF(:[Adjusted Document Due Date]:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) BETWEEN @@UDM_ARBUCKET02_MIN AND @@UDM_ARBUCKET02_MAX\nAND UDM_STGARHIST.REMBALFLAG = 0\nTHEN UDM_STGARHIST.AMOUNTTC\n\n+ \nCASE WHEN UDM_STGARHIST.HISTOTYPE = 2 AND BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.PAYAMTTC ELSE 0 END\n\nELSE 0\nEND"]
["*SERVER","*SERVER","FLD00000014","Overdue TC","@@UDM_ARBUCKET03_MIN-@@UDM_ARBUCKET03_MAX Days","CASE\nWHEN BI_DATEDIFF(:[Adjusted Document Due Date]:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) BETWEEN @@UDM_ARBUCKET03_MIN AND @@UDM_ARBUCKET03_MAX\nAND UDM_STGARHIST.REMBALFLAG = 0\nTHEN UDM_STGARHIST.AMOUNTTC\n\n+ \nCASE WHEN UDM_STGARHIST.HISTOTYPE = 2 AND BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.PAYAMTTC ELSE 0 END\n\nELSE 0\nEND"]
["*SERVER","*SERVER","FLD00000015","Overdue TC","@@UDM_ARBUCKET04+ Days","CASE\nWHEN BI_DATEDIFF(:[Adjusted Document Due Date]:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= @@UDM_ARBUCKET04\nAND UDM_STGARHIST.REMBALFLAG = 0\nTHEN UDM_STGARHIST.AMOUNTTC\n\n+ \nCASE WHEN UDM_STGARHIST.HISTOTYPE = 2 AND BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.PAYAMTTC ELSE 0 END\n\nELSE 0\nEND"]
["*SERVER","*SERVER","FLD00000016","Transaction Currency","Amount Due","UDM_STGARHIST.AMOUNTTC\n\n+ \nCASE WHEN UDM_STGARHIST.HISTOTYPE = 2 AND BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.PAYAMTTC ELSE 0 END"]
["*SERVER","*SERVER","FLD00000017","Transaction Currency","Amount Overdue","CASE\nWHEN BI_DATEDIFF(:[Adjusted Document Due Date]:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) > 0\nAND UDM_STGARHIST.REMBALFLAG = 0\nTHEN UDM_STGARHIST.AMOUNTTC\n\n+ \nCASE WHEN UDM_STGARHIST.HISTOTYPE = 2 AND BI_DATEDIFF(:UDM_STGARHIST.APPLDATE:,: BI_TODATE(:'$$DATE','$$FORMAT':) :) >= 0 THEN UDM_STGARHIST.PAYAMTTC ELSE 0 END\n\nELSE 0\nEND"]