For example, (Yes|No) means “use either Yes or No”. You must do this for any regex expression. ? means use a number between 0 and 9 or nothing.This is similar to the LIKE expression in SQL Server. Those square brackets are to denote a collection of characters and the ‘-‘ sign means ‘and all the ASCII characters between the two in the ASCII sequence’. Let’s tackle this reverse regex piece-by-piece, starting with the first expression, which generates the house number: | Avenue | Road | Parkway | Freeway | Drive | Boulevard | Blvd. SQL Data Generator out-of-the-boxįor demonstrating the features of SDG in this article, all we need is a customer address table, which you can recreate using the following code: As an example of what’s possible, in this article I’ll show how to generate realistic UK addresses. With a little tweaking, and a basic grasp of ‘reverse regex’ expressions, a tool like SQL Data Generator (SDG) can do the job very well. How do you generate data that gives you realistic-looking addresses for your part of the world? However, you do need to develop and test the database with data that reflects reasonably accurately the nature of your customer data. You want to run some database tests but you can’t use real production data because it contains personal data, including customer names, addresses, and so on. He is a regular contributor to Simple Talk and SQLServerCentral. Phil Factor (real name withheld to protect the guilty), aka Database Mole, has 30 years of experience with database-intensive applications.ĭespite having once been shouted at by a furious Bill Gates at an exhibition in the early 1980s, he has remained resolutely anonymous throughout his career.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |