Payments are experiencing issues due to temporary restrictions in Russia. If your payment does not go through, please submit a support request.Our support team is available 24/7 — we are always here to help with hosting and server issues.We are now accepting requests for dedicated server rental and colocation services in our data center.Reminder: we recommend enabling backups for additional data protection.A new VPS/VDS lineup with NVMe storage and improved performance is now available.Maintenance work on some servers has been completed. All services are operating normally.
Article5 min readViews0

Lowest Price in the Price List: Why Buying from Two Suppliers Can Be More Expensive

On a test cart, we count items and two deliveries, find the volume threshold, and determine what conditions are missing for automatic supplier selection.

Comments 0

Vera with a tablet for notes compares two shipments: choosing a supplier based on the entire purchase
In this article

The integration collected supplier price lists and identified the lowest price in each row. It seems we just need to automatically send orders. But if goods leave from two warehouses instead of one, the savings in individual rows may disappear even before acceptance testing. For a store, it is more useful to compare the total cost of the executable purchase.

Start with a simple calculation on a single cart. It will show what conditions need to be passed to the supplier selection system and where an automatic rule cannot be left unchecked. Below are test prices, not offers from real companies.

Two Cheap Rows Result in an Expensive Cart

The store needs one unit each of products X and Y. Supplier A sells product X for 900 rubles and Y for 1,100 rubles. Delivery of this entire purchase to the store warehouse costs 200 rubles. Total for A: 900 + 1,100 + 200 = 2,200 rubles.

Supplier B sells item X for 850 rubles, Y for 1,200 rubles, and shipping costs 250 rubles. The entire purchase from B totals 850 + 1,200 + 250 = 2,300 rubles. If we select only the lowest row prices, we order X from B and Y from A. The product total drops to 1,950 rubles, but two shipments add 450 rubles. The final cost is 2,400 rubles, which is 200 rubles more than buying everything from A.

In this model, products are fully comparable, available in the required quantities, and arrive within the same acceptable timeframe. Taxes are accounted for identically, and other costs are equal. The cost of each delivery is fixed and does not change based on the distribution of these two items. In a real-world scenario, each of these assumptions must be verified; otherwise, different conditions are being compared.

Cost per pair of items including delivery: Supplier A — 2,200 rubles, B — 2,300 rubles, mixed purchase — 2,400 rubles
Sample cart: savings on product lines do not offset the second delivery.

Volume can change the decision

Now we purchase multiple identical pairs of X and Y. Assume the stated prices and fixed shipping remain constant for any quantity of pairs considered. Then, purchasing from A costs 2,000 rubles per pair plus 200 rubles for delivery. A split purchase costs 1,950 rubles per pair plus 450 rubles for two shipments.

Splitting saves 50 rubles per pair but adds 250 rubles in shipping. For five pairs, the options are equal: both cost 10,200 rubles. For six pairs, purchasing from Supplier A costs 12,200 rubles, while the split option costs 12,150 rubles. The difference is only 50 rubles. If processing the second order requires additional billable actions, those must also be included in the comparison.

This threshold applies only to our model. The supplier may have a minimum order value, packaging multiples, a free shipping threshold, or a different rate for heavy cargo. In such cases, costs change in steps, and the number five ceases to be a rule. The system must calculate based on the actual conditions of the specific shipment, not store a previously found threshold as a universal constant.

The cost difference between the mixed purchase and Supplier A is 250 minus 50 rubles per pair; equality is reached at five pairs.
The threshold holds only when prices are unchanged and shipping is fixed: five pairs cost 10,200 rubles in both options.

First compatibility, then minimum

The same name does not mean the same procurement unit. The price per unit, a pack of ten, or a box containing multiple packs requires conversion to a consistent unit. The exact product variant, completeness, and acceptable substitutions matter. A cheap line item with an unsuitable variant does not participate in the selection on equal footing with the required product.

Check the price date and quantity availability. Stock levels in the price file may reflect the moment the file was generated; the store must understand when availability is confirmed by the supplier. If reservation is required, its result is a separate condition. The mere fact of loading the price file does not guarantee that a purchase will be executed.

The deadline should also be set as a constraint. If a product is needed by a specific date, a delivery arriving later is not suitable simply because the price is lower. You cannot compare an urgent confirmed delivery with waiting for stock arrival as two equivalent ways to fulfill an order. First, eliminate unacceptable options, then calculate the cost of the remaining ones.

What to entrust to the integration

Before development, record the input data: normalized products and units, required quantities, available warehouses, delivery conditions and minimum order requirements, price freshness, and acceptable deadlines. For each field, it must be clear where the data comes from and how missing values are handled. Unknown delivery options must not be silently equated to zero.

The response should show not only the selected supplier but also the cost breakdown: products, delivery fees, and other accounted expenses. Alongside, display constraints and unknown conditions that require the decision to be confirmed. This allows the manager to explain the choice and spot outdated tariffs before sending the order.

Testing the rule is convenient on pre-approved sample carts: a small one, a larger one, one with unavailable items, and one crossing the tariff threshold. The expected result is calculated separately. This set helps validate the implementation but does not prove that all future price lists and restrictions are processed correctly. This article covers the arithmetic; the specific module's behavior on the staging environment was not verified.

Automated supplier selection yields clear results when optimizing executable purchases with known costs. If the system can only compare line prices, it serves as a useful hint for the manager. The right to place orders independently should be granted only after the calculation includes conditions capable of changing the final outcome.

Discussion 0

Share your experience and ask questions. Comments without links appear after editorial review.

No comments yet. Start the discussion.