Skip to main content

MGCEarmarkInboundPricingPolicyEntity

Read/write. The copy-config feed for inbound pricing policies, for moving them from a configuration environment to test and then to production. Writes go through the policy table's own validation rather than around it, so an imported policy meets exactly the refusals a person meets on the form - which matters here because a self-contradictory policy does not fail loudly, it silently never matches. The key is the natural key, so re-running the same file updates the same rows instead of duplicating them.

  • Public collection name: MGCEarmarkInboundPricingPolicies
  • Primary key: CustomerCode, CustomerRelation, OriginCode, SalesOriginId, EffectiveFrom

Fields​

NameTypeMandatoryDescription
CustomerCodeMGCEarmarkAccountSelectorYesHow broadly this policy applies across customers - one account, a customer group, or all customers. It is the same vocabulary a deal's targeting is written in, so a policy and a deal can be read side by side. When it names something, the customer relation is required; when it is All, the relation must be blank, because a row saying "all customers, and also this one" is two contradictory statements and a reader cannot tell which was meant.
CustomerRelationMGCEarmarkAccountRelationNoThe customer account or customer group this policy applies to, read according to the customer code. Blank when the code is All.
OriginCodeMGCEarmarkOriginSelectorYesHow broadly this policy applies across sales origins - one origin, or all of them. The same required-or-blank rule holds as for the customer: a policy that names All origins must leave the origin blank.
SalesOriginIdSalesOriginIdNoThe sales origin this policy applies to, read according to the origin code. Blank when the code is All. It is how a nightly distributor file and a web store's trickle can be given different instructions even for the same customer.
EffectiveFromTransDateNoThe first date this policy applies. Blank means it has always applied. It is part of the key, so a later instruction is a new row rather than an edit to the running one, and the history of what the estate was told to do survives.
EffectiveToTransDateNoThe last date this policy applies. Blank means it applies until further notice. A window that ends before it starts can never match and is refused, because it would sit in the setup list looking active.
ActionMGCEarmarkInboundPricingActionNoWhat to do with a line in this policy's scope - nothing, propose and hold, or build and accept every eligible deal. THE DEFAULT IS TO DO NOTHING, deliberately and not merely conveniently: a policy row created and left half-finished, or imported from a file with the action column missing, changes nothing about what the estate does. The alternative ordering would have every unset row in the estate committing money.
BaseSourceMGCEarmarkInboundBaseSourceNoWhere a build made under this policy takes its base price from - the value the incoming document supplied, falling back to the native price, or the native price only. Choose native price only when the sending system is not trusted to price.
PriorityMGCEarmarkPriorityNoBreaks ties between policies of EQUAL specificity. It does not select: resolution is by specificity first, so a policy naming this customer and this origin always beats one naming the customer and all origins, whatever their priorities say.

Mappings​

Entity fieldData sourceField
CustomerCodeMGCEarmarkInboundPricingPolicyCustomerCode
CustomerRelationMGCEarmarkInboundPricingPolicyCustomerRelation
OriginCodeMGCEarmarkInboundPricingPolicyOriginCode
SalesOriginIdMGCEarmarkInboundPricingPolicySalesOriginId
EffectiveFromMGCEarmarkInboundPricingPolicyEffectiveFrom
EffectiveToMGCEarmarkInboundPricingPolicyEffectiveTo
ActionMGCEarmarkInboundPricingPolicyAction
BaseSourceMGCEarmarkInboundPricingPolicyBaseSource
PriorityMGCEarmarkInboundPricingPolicyPriority