A good algorithm for generating an order number

前端 未结 10 1455
青春惊慌失措
青春惊慌失措 2021-01-31 06:27

As much as I like using GUIDs as the unique identifiers in my system, it is not very user-friendly for fields like an order number where a customer may have to repeat that to a

10条回答
  •  北恋
    北恋 (楼主)
    2021-01-31 07:00

    We do TTT-CCCCCC-1A-N1.

    • T = Circuit type (D1E=DS1 EEL, D1U=DS1 UNE, etc.)
    • C = 6 Digit Customer ID
    • 1 = The customer's first location
    • A = The first circuit (A=1, B=2, etc) at this location
    • N = Order type (N=New, X=Disconnect, etc)
    • 1 = The first order of this kind for this circuit

提交回复
热议问题