Search Postgresql Archives

Re: Generating sample data

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



----- Original Message -----
> From: "Rich Shepard" <rshepard@xxxxxxxxxxxxxxx>
> To: pgsql-general@xxxxxxxxxxxxxx
> Sent: Tuesday, December 27, 2016 7:23:46 PM
> Subject: Re:  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



-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux