What is the difference between an SKU and an SPU in an e-commerce project?

Category: Category is a system of tree structure, which can be roughly divided into 4-5 levels. Such as mobile phone -> smart phone -> iPhone category, in this, mobile phone is the first category, iPhone is the third category, but also leaf category.

Standard Product Unit (SPU) : iPhone 6 (the smallest Unit of aggregated Product information). For example, iPhone > iPhone > iPhone 6. IPhone 6 is the SPU.

SKU(stock keeping unit) : 16GB Apple 6 (minimum non-separable unit)

Broadly speaking, category >SPU>SKU.

Summary: From the perspective of software users, taking Taobao as an example, many items can be found under “mobile phone” in the search box, which is the SPU standard product unit used by various merchants for sale. It is leaf classification of commodity classification list. For each SPU, click “enter”, but you can’t click “buy” directly. You need to select various attributes to uniquely determine which goods should be sent out of the warehouse and click “buy” after confirming, which is skU stock keeping unit, namely the minimum inventory unit.

From the perspective of software developers, for the same commodity SPU, only one record of the same attributes of multiple SKUs is saved in the data table, which is the SPU table. The different attributes of each SKU are saved in the data table, which is the SKU table.

Amount, points and e-coupon count in e-commerce projects

The amount, points and e-coupon counts in e-commerce projects are all integers in mysql and BigInteger or Long in Java