MKoD - D Programming Language
Randomly generated names and addresses for a personnel table - D Project
This is personal project I worked on at home after work two years ago, and had gotten it nearly 90% done at the time. But life, has a way turning your focus onto other things, yet I had always wanted to finish it. The main idea behind it, is to create realistic randomly generated personnel names, gender, birthdays, phone numbers and full addresses for the creation of a set of personnel tables into a company database for testing data purposes. And if you've ever seen some of the dummy data that people create into their testing databases, then you'll know why I thought this kind of project would be worth while to make. :)
Currently I'm working toward creating a USA only version (since I collected and formated the data already needed), but once I've finished this project it would be nice, to turn around and do an International version. We'll see.
24.Aug.04: After having converted wincon.h, sql.h, sqlext.h, sqltypes.h, and sqlucode.h to D I'm beginning to have a small foundation in which to start building a console front-end with ODBC32.DLL support, that'll give me the ability to gather / store data to and from a Database. Also with Walter (he's a very busy man!) finally putting the ifind() and irfind() functions into Phobos, I can now start moving on writing my text-based functions...my project's work-horses. Plus, I've decided to rename the propercase() function to asciiProperCase(), which should better identity that this function operates only on 7-bit ASCII (0x00 thru 0x7F) characters...as I'm very sure Regan Heath and Arcane Jill the D unicode experts would be quick to point out, once I've placed a link to this code on the D forum. :P
17.Nov.04: Well after reworking all the XML data files a bit to make them smaller (they're nearly half the size now), and reformated them some so they'll work better with my Text-Based/Read Only XML Class, that I'm calling "toyXML" (mainly because I had designed three different XML Classes and the simplest one based off my original VB6 design won out), I've decided to put the data up for downloading. Hopefully within a few more weeks I should have the D code ready for downloading as well. In which, the code will be designed (Stage I) to run as a commandline app that'll use a config-type setup XML file, and to output the randomizes data as XML files. Later I'll focus on a more GUI frontend type of app (Stage II) with options to export the data into a Database using the ODBC32 APIs, and to create different types of export files (XML, Comma-Delimited, Fixed-Length, and etc.) for later importing into a Database. :))
03.Dec.04: The console only version (Stage I) is how ready for people to use, please download both zipfiles ( one's the XML data, and the other one the D code ). Enjoy! It may take me a while on the GUI frontend (Stage II)...I'll need to play around bit with some of the GUI librarys, before moving forward. Meanwhile I do plan to keep updating the console version, because afterall it's the core logic to be used in the GUI version and cause I haven't added everything I want yet into this current build.
08.Jan.05: A special thanks goes out to Simon Sweetman for the eMail that pointed out a good web site to get even more names...in fact, "Last Names" have increased a to whopping 88,588 entries, plus the "Male and Female First Names" are a little bit larger than before as well. Which is why the download zipfile has almost doubled in size, and why the "Random Data" program will take many times longer to process too. But the idea is to create data once and import into a database...so I don't see this as a "Show Stopper," in fact it makes for much better random data! (Plus, I'll focus on tuning the D code a little later on...so it won't be that bad.)
29.Jan.05: Increased USA_street_names.xml from 1,000 entries to 4,000 street names.
27.Feb.05: Increased USA_female_first_names.xml from 5,114 entries to 9,462 names, and USA_male_first_names.xml from 2,178 entries to 5,408 names.
10.Jun.05: Recompiled and tested with dmd v0.126.
17.Sep.05: Recompiled and tested with dmd v0.131, also added 128 Female first names.
18.Sep.05: Did some performance turing to the code, which saves 5 minutes on a 23 minute process (based on multiple runs done on my 1.8Ghz Intel) when creating 10,000 entries.
14.Jan.06 Recompiled and Tested with dmd v0.143.
26.Mar.06 Recompiled and Tested with dmd v0.150, and added the genBirthDate() function which takes in the age of the person as an input parameter to create a birth date for them.