Re: Generating sample data

From: "btober(at)computer(dot)org" <btober(at)broadstripe(dot)net>
To: Rich Shepard <rshepard(at)appl-ecosys(dot)com>
Cc: pgsql-general(at)postgresql(dot)org, angus(at)raingod(dot)com
Subject: Re: Generating sample data
Date: 2016-12-28 02:32:07
Message-ID: 1285813312.124899411.1482892327155.JavaMail.zimbra@broadstripe.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

----- Original Message -----
> From: "Rich Shepard" <rshepard(at)appl-ecosys(dot)com>
> To: pgsql-general(at)postgresql(dot)org
> Sent: Tuesday, December 27, 2016 7:23:46 PM
> Subject: Re: [GENERAL] Generating sample data
>
> On Tue, 27 Dec 2016, Adrian Klaver wrote:
>
> > As it happens there is a Python version of the a fore mentioned faker:
> > https://pypi.python.org/pypi/Faker/0.7.7
>
> Adrian,
>
> Impressive and complete. It will generate all the data I need.
>

This is kind of fun:

https://github.com/bmtober/groan

I had to hunt down the original author from the 1990's, which was when I originally downloaded from his personal web site at

http://raingod.com/raingod/resources/Programming/Perl/Software/Groan/

The initial commit on that github page is the original source as provided by Mr. McIntyre.

In a subsequent commit, I removed some of the original code that formatted for HTML output, leaving just plain text, and also posted an example grammar for generating fake names and strings that look like social security numbers (i.e., a U.S. taxpayer identification).

The script will generate duplicates, but you can do something like

for n in {1..20}
do
groan.pl ssn.gn
done | sort -u

to get unique source data.

By defining other custom grammars, you could potentially generate all kinds of data.

-- B

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Martijn Tonies (Upscene Productions) 2016-12-28 09:04:22 Re: Generating sample data
Previous Message Rich Shepard 2016-12-28 00:23:46 Re: Generating sample data