JL Argentine Payables Withholding Flat File - draft

Description
Categories: BI Publisher
Columns: Document Date, Document Number, Document Amount, Dgi Tax Type Code, Dgi Tax Regime Code, Withholding Code, Supplier Condition Code, Withholding Amount, Exemption Percentage, Bulletin Issue Date ...
Application: Latin America Localizations
Source: Argentine Payables Withholding Flat File (XML) - Not Supported: Reserved For Future Use
Short Name: JLARPWFF_XML
DB package: JL_JLARPWFF_XMLP_PKG
SELECT	jlc.awt_date document_date,
substr(lpad(jlc.bank_account_num,30,'0'),length(lpad(jlc.bank_account_num,30,'0'))-4,5)||'#'||substr(lpad(jlc.check_number,15,'0'),length(lpad(jlc.check_number,15,'0'))-5,6) document_number,
abs(nvl(jlc.taxable_base_amount,0))  document_amount,
lpad(substr(nvl(jat.dgi_tax_type_code,'0'),1,3),3,'0') dgi_tax_type_code,
lpad(substr(nvl(atc.global_attribute5,'0'),1,3),3,'0') dgi_tax_regime_code,
'1' withholding_code,
lpad(substr(nvl(atc.global_attribute20,'0'),1,2),2,'0') supplier_condition_code,
abs(jlc.withholding_amount)  withholding_amount