Re: [sqlite] Import feature requests

2009-12-14 Thread Walter Dnes
't intend to. Let's just say I'm rather frustrated with some defaults. If I felt SQLite was useless I wouldn't be using it. I read about the "loose typing" during import, in the docs. It was only via "the hard way" that I found out just *HOW* loose. -- Walte

[sqlite] Import feature requests

2009-12-13 Thread Walter Dnes
to behave any differently from NULL? c) why on earth would I want a "zero-length string" in an *INTEGER* or *REAL* field??? That is a totally insane default. -- Walter Dnes <waltd...@waltdnes.org> ___ sqlite-users

Re: [sqlite] SQLite version 3.6.21

2009-12-13 Thread Walter Dnes
create table test(fieldname integer)' -- Walter Dnes <waltd...@waltdnes.org> ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

[sqlite] [SOLVED] How do I properly import numbers from CSV?

2009-12-07 Thread Walter Dnes
On Sun, Dec 06, 2009 at 11:26:42PM -0500, Walter Dnes wrote > I still don't understand why 2009, *WITHOUT QUOTES* would be forced > to text, i.e. ' 2009', when imported into a field that is declared > as integer in the create statement. There are actually 2 solutions... 1) Use tab-

[sqlite] How do I properly import numbers from CSV?

2009-12-06 Thread Walter Dnes
On Sun, Dec 06, 2009 at 08:15:46PM -0600, Jay A. Kreibich wrote > On Sun, Dec 06, 2009 at 07:54:45PM -0500, Walter Dnes scratched on the wall: > > > The last few rows of the query output are... > > > > 2009| 9| 21 > > 2009| 9| 22 > > 2009| 9| 23

[sqlite] Not matching numbers in where clause

2009-12-06 Thread Walter Dnes
, local_month) Is that allowed, or would it screw things up? -- Walter Dnes <waltd...@waltdnes.org> ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

[sqlite] [solved] SQLite won't import 53, 066, 244 row 11 gigabyte CSV file

2009-11-28 Thread Walter Dnes
be done upstream (i.e. by the SQLite people themselves) soon, then don't do anything. The Gentoo version will automatically inherit the large file support with the new version. -- Walter Dnes <waltd...@waltdnes.org> ___ sqlite-users mailing list s

[sqlite] SQLite won't import 53,066,244 row 11 gigabyte CSV file

2009-11-27 Thread Walter Dnes
can run "split -l dly04.csv", and import the separate (smaller) pieces. Am I correct in assuming that multiple ".import" statements will append to an existing table, rather than overwriting? (Yes, I am new to SQLite). -- Walter Dnes <waltd...@waltdnes.org> _

[sqlite] Suggested user-defined-function example

2009-11-18 Thread Walter Dnes
ot;} db eval {select addnum(1, 2) as z from dual} {puts stdout "$z"} db close And the output is... Hello world 999 3 Use this code as an example, and it may save someone else some time down the road. -- Walter Dnes <waltd...@waltdnes.org>

[sqlite] Problem passing SQLite field values to TCL function

2009-11-18 Thread Walter Dnes
as select e_stnid, i_stnid, deci_lat, deci_long, elevation, stn_name, distance( $lat_degrees, $long..." invoked from within "if { $argc < 4 } { puts "Error: This query requires at least 4 parameters, namely" puts "Central Latitude, Cent

Re: [sqlite] Disk activity on Linux

2009-11-13 Thread Walter Dnes
linux machine is a server, running in text mode, rather than a resource-heavy GUI. -- Walter Dnes <waltd...@waltdnes.org> ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] [SOLVED] Problems passing parameters between SQLite + TCL

2009-11-11 Thread Walter Dnes
On Wed, Nov 11, 2009 at 02:41:50AM -0500, Walter Dnes wrote > proc sql_distance {lat1, long1, lat2, long2} { It seems that "the TCL way" to pass multiple parameters is... proc sql_distance {lat1 long1 lat2 long2} { i.e. as a list without any commas. -- Walte

Re: [sqlite] any keyword

2009-11-11 Thread Walter Dnes
ding your query. Can you use a subquery... SELECT G.id,name FROM Genre G WHERE G.id IN ( SELECT genre_id FROM Song ) ORDER BY name ASC; -- Walter Dnes <waltd...@waltdnes.org> ___ sqlite-users mailing list sqlite-users@sqlite.org http://sq

[sqlite] Problems passing parameters between SQLite + TCL

2009-11-10 Thread Walter Dnes
23.7" error message shows that I successfully passed the first 2 command line parameters and the last 2 came from an entry in table cl.stations. Given that all 4 parameters hace been passed tothe distance() function, why are they undefined in the proc? -- Walter Dnes <waltd...@waltdnes.org>

Re: [sqlite] How do I output multi-word strings without braces?

2009-11-10 Thread Walter Dnes
On Tue, Nov 10, 2009 at 03:06:08AM -0500, Walter Dnes wrote > Given the following code fragment... > > set xname [db eval { select name from elements where e_mtid = $element }] > puts [format "Requested element ==> %s ==> %s" $element $xname] Oops, I forgot to

[sqlite] How do I output multi-word strings without braces?

2009-11-10 Thread Walter Dnes
e so... Requested element ==> abcdef ==> {FOO BAR} What I need is... Requested element ==> abcdef ==> FOO BAR What do I need to do to get rid of the braces around the output name? And no, that's not how the data looked in the tab-delimited file it was imported from.