hell and sqlite

Hi everyone,

I have a requirement that requires me to fill an sqlite database with 100,000 entries (no duplicates).

I will start out by giving the command that will insert the values necessary to populate the database:

# sqlite /var/local/database/dblist "insert into list (owner_id,behavior,entry)

values(0,0,'newblacklistentry.com') "

The challenge would be to get a different output for the entry value 100,000 times!

We can start with newurl.com and maybe append a numerical character to the string e.g.

newurl1.com
newurl2.com
newurl3.com

  • I'm running on Linux

Your thoughts?

Thanks for looking :slight_smile:

Carlo

try this:

#!/bin/sh
i=1
while [ $i -le 50 ]
do

sqlite /var/local/database/dblist "insert into list (owner_id,behavior,entry) values(0,0,'newblacklistentry$i.com') "

  i=`expr $i + 1`
done

if it works turn the value "50" to "100000" and let it roll :slight_smile:

Awesome! Works :slight_smile:

Thanks scarfake :b: That's how we roll!