Re: [sqlite] What is the easiest way of changing the field type?

2012-12-03 Thread Keith Medcalf
How about trying to write .output to the same file you are .read ing? I would expect it to explode. Further, I would expect it quite likely that it would explode without being able to tell you about the explosion. The sequence should be: .output somefile .dump sometable .output stdout ...

Re: [sqlite] What is the easiest way of changing the field type?

2012-12-03 Thread Simon Davies
On 3 December 2012 19:29, Igor Korot wrote: > Simon, > > On Mon, Dec 3, 2012 at 11:03 AM, Simon Slavin wrote: >> >> On 3 Dec 2012, at 6:53pm, Igor Korot wrote: >> > > Here is the session: > > sqlite> CREATE TABLE test(id1 integer,

Re: [sqlite] What is the easiest way of changing the field type?

2012-12-03 Thread Simon Slavin
On 3 Dec 2012, at 7:29pm, Igor Korot wrote: > I didn't get errors when I did that with my table. Other than that its all > the same. You didn't get any time shown when the .read command finished. This suggests that something crashed the .read command. Anything done after

Re: [sqlite] What is the easiest way of changing the field type?

2012-12-03 Thread Igor Korot
Simon, On Mon, Dec 3, 2012 at 11:03 AM, Simon Slavin wrote: > > On 3 Dec 2012, at 6:53pm, Igor Korot wrote: > >> Yes, using standard sqlite3 shell from command prompt in Windows 7 64-bit. >> After .dump/.read no queries to the table in question produced

Re: [sqlite] What is the easiest way of changing the field type?

2012-12-03 Thread Simon Slavin
On 3 Dec 2012, at 6:53pm, Igor Korot wrote: > Yes, using standard sqlite3 shell from command prompt in Windows 7 64-bit. > After .dump/.read no queries to the table in question produced output. > > When restarted the shell everything worked. I've not come across that

Re: [sqlite] What is the easiest way of changing the field type?

2012-12-03 Thread Igor Korot
Simon, On Mon, Dec 3, 2012 at 9:39 AM, Simon Slavin wrote: > > On 3 Dec 2012, at 5:38pm, Igor Korot wrote: > >> Simon, >> Yes, thank you. > > Great. > >> ALL, >> After recreating the table this way I had to restart sqlite console as >> otherwise >> all

Re: [sqlite] What is the easiest way of changing the field type?

2012-12-03 Thread Simon Slavin
On 3 Dec 2012, at 5:38pm, Igor Korot wrote: > Simon, > Yes, thank you. Great. > ALL, > After recreating the table this way I had to restart sqlite console as > otherwise > all queries to the table were dead. > > Is this normal? Hmm. No, if you're using the standard

Re: [sqlite] What is the easiest way of changing the field type?

2012-12-03 Thread Igor Korot
Simon, Yes, thank you. ALL, After recreating the table this way I had to restart sqlite console as otherwise all queries to the table were dead. Is this normal? Thank you. On Mon, Dec 3, 2012 at 1:42 AM, Simon Slavin wrote: > > On 3 Dec 2012, at 1:08am, Igor Korot

Re: [sqlite] What is the easiest way of changing the field type?

2012-12-03 Thread Simon Slavin
On 3 Dec 2012, at 1:08am, Igor Korot wrote: > I thought that simply using ".backup/.restore" will give me what I want, > but it gives me a file in internal format. > What I am trying to do is do make a text file which gives me all SQL command > that was issued (CREATE TABLE

Re: [sqlite] What is the easiest way of changing the field type?

2012-12-02 Thread Donald Griggs
Regarding: > > > > Note that you only need to .dump/.read the table(s) you want to alter. > > *Well, I don't think it's true. > 1. When I execute "CREATE TABLE" with the table name that already exists > wouldn't I get an error message? > 2. If I drop this table first I will get an error about the

Re: [sqlite] What is the easiest way of changing the field type?

2012-12-02 Thread Igor Korot
Donald, On Sun, Dec 2, 2012 at 7:22 PM, Donald Griggs wrote: > Regarding: > > *How do I do that? > I thought that simply using ".backup/.restore" will give me what I want, > but it gives me a file in internal format. > What I am trying to do is do make a text file which gives

Re: [sqlite] What is the easiest way of changing the field type?

2012-12-02 Thread Donald Griggs
Regarding: *How do I do that? I thought that simply using ".backup/.restore" will give me what I want, but it gives me a file in internal format. What I am trying to do is do make a text file which gives me all SQL command that was issued (CREATE TABLE and INSERT) than fix the particular CREATE

Re: [sqlite] What is the easiest way of changing the field type?

2012-12-02 Thread Igor Korot
Jay, On Sun, Dec 2, 2012 at 1:31 PM, Jay A. Kreibich wrote: > On Sun, Dec 02, 2012 at 12:52:33PM -0800, Igor Korot scratched on the wall: >> Jay, >> >> On Sun, Dec 2, 2012 at 12:16 PM, Jay A. Kreibich wrote: >> > On Sun, Dec 02, 2012 at 11:58:54AM -0800, Igor

Re: [sqlite] What is the easiest way of changing the field type?

2012-12-02 Thread Jay A. Kreibich
On Sun, Dec 02, 2012 at 12:52:33PM -0800, Igor Korot scratched on the wall: > Jay, > > On Sun, Dec 2, 2012 at 12:16 PM, Jay A. Kreibich wrote: > > On Sun, Dec 02, 2012 at 11:58:54AM -0800, Igor Korot scratched on the wall: > >> Hi, ALL, > >> ALTER TABLE command does not support

Re: [sqlite] What is the easiest way of changing the field type?

2012-12-02 Thread Gerry Snyder
On 12/2/2012 1:52 PM, Igor Korot wrote: So, does this mean that I need to drop the DB in the text file, edit it and then re-create it from this file? How to make alterations to a table that can not be done with the ALTER TABLE command is outlined in topic 11 of the FAQ:

Re: [sqlite] What is the easiest way of changing the field type?

2012-12-02 Thread Igor Korot
Jay, On Sun, Dec 2, 2012 at 12:16 PM, Jay A. Kreibich wrote: > On Sun, Dec 02, 2012 at 11:58:54AM -0800, Igor Korot scratched on the wall: >> Hi, ALL, >> ALTER TABLE command does not support changing the field type. >> >> What is the easiest and fastest way to change the field

Re: [sqlite] What is the easiest way of changing the field type?

2012-12-02 Thread Jay A. Kreibich
On Sun, Dec 02, 2012 at 11:58:54AM -0800, Igor Korot scratched on the wall: > Hi, ALL, > ALTER TABLE command does not support changing the field type. > > What is the easiest and fastest way to change the field type from > integer to double? The easy, fast, and dangerous method is to edit