US Army Serial Number Generator
The date the person joined the service is actually only necessary for officers and warrant officers, whose serial number format changed slightly in 1931 and 1941, respectively.
The state of induction is only applicable to enlisted men. In other cases, the program ignores it. The country was divided into 10 zones, each of which was a group of 1-9 states. The zone number was used as the second or third digit (depending on service) of enlisted men's serial numbers. It was unclear to the programmer whether Hawaii was coded as 10 or 0; to avoid confusion, 0 is used here.
For the sake of space, hospital dieticians, physical therapists, and contract surgeons have been omitted; they, or at least their serial numbers, are unlikely to turn up in fanfic.
If you've ever wondered, General Patton's ASN was O-2605. Now you know.
The data on dog tags come from Strictly G.I., an excellent website. Any errors are undoubtedly mine. Strictly G.I. has a great deal of information that could be useful in writing. At the time of the creation of this page, Strictly G.I. was in the process of moving, so the availability of any given information may be sporadic.