I backed up my database from Postgres 6.5.3 and migrated to 7.0.2
several a few months ago. For some reason, data was lost in the
transition. I've finally pinned it down to the attached file (abridged
to point out the problem).
It looks like two things happened in the backup. First, when I move from
'G' to 'F' in the names column, I seem to lose the column called
'dsp_chan'. Second, the double quotes around the float_4 array called
'spike_hist' aren't included.
I'm not sure if the double quotes are necessary, but the missing column
is probably a problem. I added this column after the database was
created by using 'alter table ellipse_cell_proc add column dsp_chan' and
then put it in the correct position by using:
SELECT name, arm, rep, cycle, hemisphere, area, cell, dsp_chan,
spike_hist INTO xxx FROM ellipse_cell_proc;
DROP TABLE ellipse_cell_proc;
ALTER TABLE xxx RENAME TO ellipse_cell_proc;
Can anyone explain what went wrong with the backup or where I erred
adding the column?
Thanks.
-Tony
\connect - postgres
CREATE TABLE "ellipse_cell_proc" ("name" text,"arm" character,"rep" int4,"cycle" int4,"hemisphere" character,"area"
text,"cell"int4,"dsp_chan" text,"spike_hist" "_float4"
);
COPY "ellipse_cell_proc" FROM stdin;
I L 888 2 R 4 173 1
{"0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0.4","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0"}
I L 888 3 R 4 173 1
{"0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0"}
I L 888 4 R 4 173 1
{"0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0"}
I L 888 5 R 4 173 1
{"0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0"}
G R 5 2 L 4 1 1
{"1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.6","43.9","29.4","36.3","30.4","14","2.2","2.2","2.2","2.2","2.2","2.2","2.2","2.2","2.2","2.2","2.2","2.2","2.2","2.2","2.2","2.2","7","30.3","47.5","48.5","48.2","33.9","35.6","37.8","29.6","23.3","43.7","21.3","26.6","44","39.6","35.5","35.6","46.6","41.6","43","42.1","25.7","22.7","22.7","22.1","21.3","21.9","22.2","36","26.8","29.2","30.6","21.3","22.8","24.4","9","7.6","7.6","7.6","7.6","2","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","13.3","20.4","8.1","3.9","3.9","3.9","3.9","3.9","3.9","3.9","3.9","3.9","39","10","10","10","15.9","30.5"}
G R 5 3 L 4 1 1
{"1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","1.4","9.3","20.4","20.4","10.8","3.9","3.9","3.9","3.9","3.9","3.9","3.9","3.9","3.9","3.9","3.9","3.9","3.9","3.9","31.8","31.3","10","10","10","10","10","29.6","38.8","29.4","35.6","47.6","22.7","22.7","39.8","38.6","25.6","26.1","27.8","29.2","38.5","34.6","32.3","29.2","28.6","42.3","32.8","22.2","22.2","30.7","30.3","21.3","21.3","19.3","16.1","16.1","16.1","9","7.1","7.1","7.1","7.1","7.1","7.1","7.1","3.3","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","4.6","16.9","16.9","16.9","3.2"}
G R 5 4 L 4 1 1
{"1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","1.2","9.9","16.9","16.9","17.1","17.2","17.2","19.7","20.4","13.4","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","1.7","18.3","35","41.7","64.4","70.8","54.6","66.8","54.3","43.4","48.7","15.9","15.9","14.1","6.6","6.6","6.6","6.6","6.6","6.6","6.6","2.5","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","16.7","18.9","21.4","28.6","34.8"}
G R 5 5 L 4 1 1
{"1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","1.1","9.9","18.9","18.9","25.1","28.6","37.3","38.8","37","39.9","41","28.7","2.6","2.6","2.6","2.6","2.6","2.6","2.6","2.6","2.6","2.6","2.6","2.6","2.6","2.6","2.6","2.6","2.6","2.6","2.6","2.6","14.6","16.7","16.7","36","53.2","58.8","51.4","48.9","59.9","56.2","48.5","51.6","39.1","25","15.3","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0","0"}
F L 838 1 R 3 123 { 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3,
2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3,
2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 2.3, 7.4, 11.1, 11.1,
11.1, 11.1, 11.1, 11.1, 11.1, 11.1, 11.1, 37.2, 40.0, 32.1, 3.2, 3.2, 3.2, 3.2, 3.2,
3.2, 3.2, 3.2, 3.2, 3.2, 3.2, 3.2, 3.2, 3.2, 3.2, 3.2, 3.2, 3.2, 3.2, 3.2,
3.2, 3.2, 3.2, 3.2, 3.2, 3.2, 3.2, 3.2, 3.2, 3.2, 3.2, 3.2, 3.2, 12.6, 20.0,
20.0, 20.0, 20.0, 18.9, 14.1, 14.1, 14.1, 14.1, 14.1, 14.1, 14.1, 33.8, 50.0, 43.8, 34.5,
34.5, 41.3, 58.8, 37.9, 12.5, 12.5, 12.5, 12.5, 12.5, 12.5, 12.5, 12.5, 13.8, 14.1, 14.1,
14.1, 14.1, 14.1, 14.1, 19.7, 40.0, 40.0, 46.7, 52.6, 27.2, 0.0, 0.0, 0.0, 0.0, 0.0,
0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, } \N
F L 838 2 R 3 123 { 58.8, 28.3, 12.5, 12.5, 12.5, 12.5, 12.5, 12.5, 12.5, 12.5,
12.5, 13.9, 14.1, 14.1, 14.1, 14.1, 14.1, 14.1, 14.1, 20.4, 40.0, 40.0, 42.5, 52.6, 52.6,
10.9, 5.1, 5.1, 5.1, 5.1, 5.1, 5.1, 5.1, 5.1, 5.1, 5.1, 5.1, 5.1, 5.1, 5.1,
5.1, 5.1, 5.1, 5.1, 5.1, 5.1, 5.1, 5.1, 6.0, 14.5, 14.5, 14.5, 14.5, 14.5, 14.5,
14.5, 14.5, 12.3, 11.2, 11.2, 11.2, 11.2, 11.2, 11.2, 11.2, 11.2, 11.2, 11.2, 29.6, 33.3,
33.3, 40.8, 76.9, 54.4, 38.5, 38.5, 52.1, 71.4, 53.1, 45.5, 44.6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