project QadFinancials > class BMfgTaxDetail > business logic query TaxDetailByKey

Description

TaxDetailByKey: query that returns the tax-details of operational-transactions - accesses tables tx2d_det and tx2_mstr based on the prim-key of tx2d_det


Parameters


icTx2dDomaincharacterCorresponds with tx2d_domain
icTx2dReferencecharacterCorresponds with field tx2d_ref
icTx2dNumbercharacterCorresponds with tx2d_nbr
iiTx2dLineintegerCorresponds with tx2d_line
NOTE: also tx2d_det records with tx2d_line = 0 will be returned even when you pass in a value
icTx2dTrailercharacterCorrespondfs with tx2d_trl
icTx2dTransactionTypecharacterCorresponds with tx2d_tr_type
icTx2dTaxCodecharacterCorresponds with tx2d_tax_code


query condition


  each tx2d_det where
tx2d_det.tx2d_domain = icTx2dDomain AND
tx2d_det.tx2d_ref = icTx2dReference AND
tx2d_det.tx2d_nbr = icTx2dNumber AND
tx2d_det.tx2d_trl = icTx2dTrailer AND
tx2d_det.tx2d_tr_type = icTx2dTransactionType AND
tx2d_det.tx2d_tax_code = icTx2dTaxCode AND
(tx2d_det.tx2d_line = iiTx2dLine OR
tx2d_det.tx2d_line = 0 )

      first tx2_mstr (inner-join) where
tx2_mstr.tx2_domain = tx2d_det.tx2d_domain AND
tx2_mstr.tx2_tax_code = tx2d_det.tx2d_tax_code AND


query resultset tqTaxDetailByKey


field namedata typedb fielddescription
tctx2_basecharactertx2_mstr.tx2_baseTaxable Base Code
tltx2_tax_inlogicaltx2_mstr.tx2_tax_inAllow Tax Included
tdtx2d_cur_abs_ret_amtdecimaltx2d_det.tx2d_cur_abs_ret_amtAbsorbed/Retained
tctx2_dltx_cn_subcharactertx2_mstr.tx2_dltx_cn_subDelayed Tax CN Sub-Account
tctx2_dltx_inv_acctcharactertx2_mstr.tx2_dltx_inv_acctDelayed Tax Invoice Account
tctx2_dltx_inv_subcharactertx2_mstr.tx2_dltx_inv_subDelayed Tax Invoice Sub-Account
tctx2_ap_acctcharactertx2_mstr.tx2_ap_acctAP Tax Account
tctx2_ap_cn_acctcharactertx2_mstr.tx2_ap_cn_acctAP Tax CN Account
tctx2_ap_cn_subcharactertx2_mstr.tx2_ap_cn_subAP Tax CN Sub-Account
tctx2_ap_subcharactertx2_mstr.tx2_ap_subAP Tax Sub-Account
tctx2_apr_acctcharactertx2_mstr.tx2_apr_acctAP Retained Tax Account
tctx2_apr_cn_acctcharactertx2_mstr.tx2_apr_cn_acctAP Tax Ret CN Account
tctx2_apr_cn_subcharactertx2_mstr.tx2_apr_cn_subAP Tax Ret CN Sub-Account
tctx2_apr_subcharactertx2_mstr.tx2_apr_subAP Retained Tax sub
tltx2_apr_uselogicaltx2_mstr.tx2_apr_use
tctx2_dltx_cn_acctcharactertx2_mstr.tx2_dltx_cn_acctDelayed Tax CN Account
tdtx2d_abs_ret_amtdecimaltx2d_det.tx2d_abs_ret_amtBase Absorbed/Retained
tdtx2d_cur_recov_amtdecimaltx2d_det.tx2d_cur_recov_amtRecoverable
tdtx2d_cur_tax_amtdecimaltx2d_det.tx2d_cur_tax_amtTax
tctx2d_domaincharactertx2d_det.tx2d_domainDomain
titx2d_lineintegertx2d_det.tx2d_lineLine
tctx2d_nbrcharactertx2d_det.tx2d_nbrNumber
tltx2d_rcpt_tax_pointlogicaltx2d_det.tx2d_rcpt_tax_pointAccrue Tax at Receipt
tctx2d_refcharactertx2d_det.tx2d_refReference
tdtx2d_tax_amtdecimaltx2d_det.tx2d_tax_amtBase Tax
tctx2d_tax_codecharactertx2d_det.tx2d_tax_codeTax Code
tctx2d_tax_envcharactertx2d_det.tx2d_tax_envTax Environment
tltx2d_tax_inlogicaltx2d_det.tx2d_tax_inTax In
tctx2d_tax_typecharactertx2d_det.tx2d_tax_typeTax Type
tctx2d_tax_usagecharactertx2d_det.tx2d_tax_usageTax Usage
tdtx2d_taxable_amtdecimaltx2d_det.tx2d_taxable_amtBase Taxable
tctx2d_taxccharactertx2d_det.tx2d_taxcTax Class
tdtx2d_totamtdecimaltx2d_det.tx2d_totamtTotal Amount
tdtx2d_tottaxdecimaltx2d_det.tx2d_tottaxTaxable Sales
tctx2d_tr_typecharactertx2d_det.tx2d_tr_typeTransaction Type
tctx2d_trlcharactertx2d_det.tx2d_trlTrailer
tltx2d_usage_tax_pointlogicaltx2d_det.tx2d_usage_tax_pointAccrue Tax At Usage
tctx2d_zone_fromcharactertx2d_det.tx2d_zone_fromShip-From Tax Zone
tctx2d_zone_tocharactertx2d_det.tx2d_zone_toShip-To Tax Zone
tctx2_domaincharactertx2_mstr.tx2_domainDomain
tltx2_inv_disclogicaltx2_mstr.tx2_inv_discDiscount Tax at Invoice
tdtx2_pct_recvdecimaltx2_mstr.tx2_pct_recvPercent Recoverable
tltx2_rcpt_tax_pointlogicaltx2_mstr.tx2_rcpt_tax_pointAccrue Tax at Receipt
tltx2_reverse_chargelogicaltx2_mstr.tx2_reverse_chargeDomestic Reverse Charge
tltx2_stx_dltx_uselogicaltx2_mstr.tx2_stx_dltx_useSuspended/Delayed Taxes
tctx2_tax_codecharactertx2_mstr.tx2_tax_codeTax Code
tdtx2_tax_pctdecimaltx2_mstr.tx2_tax_pctTax Rate
tltx2_update_taxlogicaltx2_mstr.tx2_update_taxUpdate Tax Allowed
tltx2_usage_tax_pointlogicaltx2_mstr.tx2_usage_tax_pointAccrue Tax At Usage


Internal usage


QadFinancials
method BAPMatching.CalculatePostAPMLnQuery
method BAPMatching.GetPendingVouchersPOShipper
method BERSProcessor.ERSProcessAPMatching
method BMFGLegalDocument.GetLegalDocumentDetForAPMatchingTax
dataset BMFGLegalDocument.tLgddDetTaxForAPM