project QadFinancials > class BDDocument > business logic query GetDeductionByDDocIDStatus


Parameters


iiCompanyIdintegerCompany id
iiDDocumentIDinteger
icDeductionStatusListcharacter


query condition


  each DDocumentInvoiceXref where
DDocumentInvoiceXref.DDocument_ID = iiDDocumentID

      first DInvoice (inner-join) where
DInvoice.Company_Id = iiCompanyId AND
DInvoice.DInvoice_ID = DDocumentInvoiceXref.DInvoice_ID AND
DInvoice.DInvoiceType = {&INVOICETYPE-DEDUCTION}

          each DInvoiceDeduction (inner-join) where
DInvoiceDeduction.DInvoice_ID = DInvoice.DInvoice_ID AND
DInvoiceDeduction.DInvoiceDeductionStatus can-do icDeductionStatusList


query resultset tqGetDeductionByDDocIDStatus


field namedata typedb fielddescription
tiDDocument_IDintegerDDocumentInvoiceXref.DDocument_IDLink to DDocument
tiDDocumentInvoiceXref_IDintegerDDocumentInvoiceXref.DDocumentInvoiceXref_IDRecord ID
tiDInvoice_IDintegerDDocumentInvoiceXref.DInvoice_IDLink to DInvoice


Internal usage


QadFinancials
method BDDocument.ValidateComponentDDocumentStatus