project QadFinancials > class BBusinessRelation > business logic query VatNumberByBusinessRelation


Parameters


iiBusinessRelationIdinteger
iiVatNumberIDToSkipintegerIf you pass as value for this parameter, then the vat-number with this ID will be not in the result-set
iiIdentityCountryIDintegerIdentityCountryID
icVatNumberIdentitycharacterVatNumberIdentity
iiBusinessRelationIDToSkipintegerBusinessRelationIDToSkip;
If you pass as value for this parameter, then the BusinessRelations with this ID will be not in the result-set


query condition


  each VatNumber where
VatNumber.BusinessRelation_ID = iiBusinessRelationId AND
VatNumber.VatNumber_ID <> iiVatNumberIDToSkip AND
VatNumber.VatNumberIdentity = icVatNumberIdentity AND
VatNumber.IdentityCountry_ID = iiIdentityCountryID AND
VatNumber.BusinessRelation_ID <> iiBusinessRelationIDToSkip

      first BusinessRelation (inner-join) where
BusinessRelation.BusinessRelation_ID = VatNumber.BusinessRelation_ID AND


query sort order


VatNumber.VatNumber_ID (ascending)


query resultset tqVatNumberByBusinessRelation


field namedata typedb fielddescription
tiBusinessRelation_IDintegerVatNumber.BusinessRelation_IDLink to BusinessRelation
tcBusinessRelationCodecharacterBusinessRelation.BusinessRelationCodeBusiness Relation. A code to identify the business relation.
If this field does not have a input from the user, the system automatically generates a number for the record based on the sequence defined in Business Relation Autonumber Create.
tcCustomCombo0characterVatNumber.CustomCombo0Custom Combo Field
tcCustomCombo1characterVatNumber.CustomCombo1Custom Combo Field
tcCustomCombo2characterVatNumber.CustomCombo2Custom Combo Field
tcCustomCombo3characterVatNumber.CustomCombo3Custom Combo Field
tcCustomCombo4characterVatNumber.CustomCombo4Custom Combo Field
tcCustomCombo5characterVatNumber.CustomCombo5Custom Combo Field
tcCustomCombo6characterVatNumber.CustomCombo6Custom Combo Field
tcCustomCombo7characterVatNumber.CustomCombo7Custom Combo Field
tcCustomCombo8characterVatNumber.CustomCombo8Custom Combo Field
tcCustomCombo9characterVatNumber.CustomCombo9Custom Combo Field
ttCustomDate0dateVatNumber.CustomDate0Custom Date Field
ttCustomDate1dateVatNumber.CustomDate1Custom Date Field
ttCustomDate2dateVatNumber.CustomDate2Custom Date Field
ttCustomDate3dateVatNumber.CustomDate3Custom Date Field
ttCustomDate4dateVatNumber.CustomDate4Custom Date Field
tdCustomDecimal0decimalVatNumber.CustomDecimal0Custom Decimal Field
tdCustomDecimal1decimalVatNumber.CustomDecimal1Custom Decimal Field
tdCustomDecimal2decimalVatNumber.CustomDecimal2Custom Decimal Field
tdCustomDecimal3decimalVatNumber.CustomDecimal3Custom Decimal Field
tdCustomDecimal4decimalVatNumber.CustomDecimal4Custom Decimal Field
tiCustomInteger0integerVatNumber.CustomInteger0Custom Integer Field
tiCustomInteger1integerVatNumber.CustomInteger1Custom Integer Field
tiCustomInteger2integerVatNumber.CustomInteger2Custom Integer Field
tiCustomInteger3integerVatNumber.CustomInteger3Custom Integer Field
tiCustomInteger4integerVatNumber.CustomInteger4Custom Integer Field
tcCustomLong0characterVatNumber.CustomLong0Custom Long Field
tcCustomLong1characterVatNumber.CustomLong1Custom Long Field
tcCustomNotecharacterVatNumber.CustomNoteCustom Note Field
tcCustomShort0characterVatNumber.CustomShort0Custom Short Field
tcCustomShort1characterVatNumber.CustomShort1Custom Short Field
tcCustomShort2characterVatNumber.CustomShort2Custom Short Field
tcCustomShort3characterVatNumber.CustomShort3Custom Short Field
tcCustomShort4characterVatNumber.CustomShort4Custom Short Field
tcCustomShort5characterVatNumber.CustomShort5Custom Short Field
tcCustomShort6characterVatNumber.CustomShort6Custom Short Field
tcCustomShort7characterVatNumber.CustomShort7Custom Short Field
tcCustomShort8characterVatNumber.CustomShort8Custom Short Field
tcCustomShort9characterVatNumber.CustomShort9Custom Short Field
tiDeclarationCountry_IDintegerVatNumber.DeclarationCountry_IDCountry Tax Declaration
tiIdentityCountry_IDintegerVatNumber.IdentityCountry_IDCountry Tax Identification
ttLastModifiedDatedateVatNumber.LastModifiedDateLast Modified Date
tiLastModifiedTimeintegerVatNumber.LastModifiedTimeLast Modified Time
tcLastModifiedUsercharacterVatNumber.LastModifiedUserLast Modified User
tiVatNumber_IDintegerVatNumber.VatNumber_IDRecord ID
tcVatNumberDeclarationcharacterVatNumber.VatNumberDeclarationObsolete field
tcVatNumberIdentitycharacterVatNumber.VatNumberIdentityObsolete field
tlVatNumberIsActivelogicalVatNumber.VatNumberIsActiveObsolete field
ti_sequenceintegercalculatedprimary index
tc_rowidcharactercalculated = rowid(VatNumber),rowid(BusinessRelation)


Internal usage


QadFinancials
method BBusinessRelation.AdditionalUpdates
method BBusinessRelation.ApiLoadBusinessRelation