Mercurial > hg > egg-tcls
annotate convert_urllog_db.tcl @ 22:7feaff7cc22e
Cleanups.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Mon, 05 Sep 2011 18:37:33 +0300 |
parents | 06f5e5b25930 |
children | 9ba859d9f931 |
rev | line source |
---|---|
10
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
1 #!/usr/bin/tclsh |
22 | 2 # TCL script for converting URLLog v1.x flat file |
3 # format database to SQLite3 database. | |
4 # | |
5 # Written by Matti 'ccr' Hamalainen <ccr@tnsp.org> | |
6 # (C) Copyright 2011 Tecnic Software productions (TNSP) | |
7 # | |
10
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
8 package require sqlite3 |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
9 |
22 | 10 ### Check commandline arguments |
11 if {$argc != 2} { | |
12 puts "Usage: $argv0 <input_flat_file_db> <output_sqlite_db_file>" | |
13 exit 0 | |
14 } | |
15 | |
16 set db_input [lindex $argv 0] | |
17 set db_output [lindex $argv 1] | |
18 set db_table "urls" | |
10
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
19 |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
20 |
22 | 21 ### Ask for confirmation |
22 puts "Conversion of '$db_input' to SQLite database '$db_output', to table '$db_table'." | |
23 puts "NOTICE! This WILL destroy the current data in table '$db_table'!" | |
24 | |
25 puts -nonewline "Proceed \[y/N\]? " | |
26 flush stdout | |
27 set response [gets stdin] | |
28 if {[string tolower $response] != "y"} { | |
29 puts "OK, aborting." | |
30 exit 0 | |
31 } | |
32 | |
33 ### Helper functions | |
10
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
34 proc escape { str } { |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
35 return [string map {' ''} $str] |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
36 } |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
37 |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
38 proc lescape { lst pos } { |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
39 return [escape [lindex $lst $pos]] |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
40 } |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
41 |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
42 |
22 | 43 ### Open flatfile for reading |
44 if {[catch {set fd [open $db_input r]} uerrmsg]} { | |
45 puts "Could not open '$db_input' for reading: $uerrmsg" | |
10
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
46 exit 1 |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
47 } |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
48 |
22 | 49 ### Open SQLite database |
50 if {[catch {sqlite3 urldb $db_output} uerrmsg]} { | |
51 puts "Could not open SQLite3 database '$db_output': $uerrmsg" | |
10
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
52 exit 2 |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
53 } |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
54 |
22 | 55 ### Drop old table |
56 puts "Dropping current '$db_table' table." | |
57 if {[catch {urldb eval {DROP TABLE $db_table}} uerrmsg]} { | |
11
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
58 puts "Dropping table resulted in error (ignored): $uerrmsg" |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
59 } |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
60 |
22 | 61 ### Create new |
62 puts "Creating new table '$db_table'." | |
63 if {[catch {urldb eval "CREATE TABLE $db_table (id INTEGER PRIMARY KEY AUTOINCREMENT, utime INT, url VARCHAR(2048), user VARCHAR(32), host VARCHAR(256), chan VARCHAR(32))}} uerrmsg]" { | |
11
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
64 puts "Error creating table! $uerrmsg" |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
65 exit 3 |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
66 } |
10
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
67 |
22 | 68 ### Detect URL database version |
11
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
69 puts -nonewline "Detecting database version: " |
10
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
70 set nline 0 |
11
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
71 set minentries 9999 |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
72 set maxentries 0 |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
73 while {![eof $fd]} { |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
74 incr nline |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
75 set line [gets $fd] |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
76 if {$line != ""} { |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
77 set items [split $line " "] |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
78 set tmp [llength $items] |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
79 if {$tmp > $maxentries} { set maxentries $tmp } |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
80 if {$tmp < $minentries} { set minentries $tmp } |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
81 } |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
82 } |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
83 |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
84 if {$maxentries != 5 || $maxentries != $minentries} { |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
85 puts "old / variable" |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
86 } else { |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
87 puts "new" |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
88 } |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
89 |
22 | 90 ### Show some information |
11
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
91 puts "Database contains $nline records, with $minentries / $maxentries entries." |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
92 |
22 | 93 |
94 ### Begin conversion | |
11
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
95 puts -nonewline "Converting database, please wait ... round #1 " |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
96 set nline 0 |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
97 seek $fd 0 start |
10
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
98 while {![eof $fd]} { |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
99 incr nline |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
100 set line [gets $fd] |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
101 set items [split $line " "] |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
102 if {$line != ""} { |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
103 set host [lindex $items 3] |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
104 if {[regexp {^\((.+)\)$} $host ures uhost]} { |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
105 set host $uhost |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
106 } |
11
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
107 set uid [lindex $items 4] |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
108 if {$uid != ""} { |
22 | 109 set sql "INSERT INTO $db_table (id,utime,url,user,host) VALUES ($uid, [lindex $items 1], '[lescape $items 0]', '[lescape $items 2]', '[escape $host]')" |
11
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
110 if {[catch {urldb eval $sql} uerrmsg]} { |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
111 puts "\nError ($nline): $uerrmsg on:\n$sql" |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
112 exit 15 |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
113 } |
10
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
114 } |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
115 } |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
116 if {[expr $nline % 10] == 1} { |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
117 puts -nonewline "." |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
118 flush stdout |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
119 } |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
120 } |
11
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
121 puts "OK" |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
122 |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
123 puts -nonewline "\nRound #2 " |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
124 set nline 0 |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
125 seek $fd 0 start |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
126 while {![eof $fd]} { |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
127 incr nline |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
128 set line [gets $fd] |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
129 set items [split $line " "] |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
130 if {$line != ""} { |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
131 set host [lindex $items 3] |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
132 if {[regexp {^\((.+)\)$} $host ures uhost]} { |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
133 set host $uhost |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
134 } |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
135 set uid [lindex $items 4] |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
136 if {$uid == ""} { |
22 | 137 set sql "INSERT INTO $db_table (utime,url,user,host) VALUES ([lindex $items 1], '[lescape $items 0]', '[lescape $items 2]', '[escape $host]')" |
11
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
138 if {[catch {urldb eval $sql} uerrmsg]} { |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
139 puts "\nError ($nline): $uerrmsg on:\n$sql" |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
140 exit 15 |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
141 } |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
142 } |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
143 } |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
144 if {[expr $nline % 10] == 1} { |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
145 puts -nonewline "." |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
146 flush stdout |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
147 } |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
148 } |
06f5e5b25930
Make the database conversion 2-staged to support old format flatfile database inputs. Add detection for old format.
Matti Hamalainen <ccr@tnsp.org>
parents:
10
diff
changeset
|
149 |
10
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
150 urldb close |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
151 close $fd |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
152 |
fbf718c24de4
Add script for converting URLLog text database to SQLite.
Matti Hamalainen <ccr@tnsp.org>
parents:
diff
changeset
|
153 puts "OK" |
22 | 154 puts "New SQLite3 database is in file '$db_output'" |