X-Git-Url: http://git.equinoxoli.org/?p=migration-tools.git;a=blobdiff_plain;f=mig-bin%2Fmig-gsheet;h=9cad4ab670de8c1850c99755b35e359e3b5b4d5b;hp=a4e089c24ad68c57ae6fc0b1d0c698208d11a965;hb=3d4d538d2127b69c73e3566c7f7eb0ce6cd542f2;hpb=2f34c8427944b6572c9e0c695b2f241b4f10cb3a diff --git a/mig-bin/mig-gsheet b/mig-bin/mig-gsheet index a4e089c..9cad4ab 100755 --- a/mig-bin/mig-gsheet +++ b/mig-bin/mig-gsheet @@ -190,7 +190,7 @@ sub export_table { my $efile = $MIGGITDIR . $table . '_' . $date . '_' . $hms . '.tsv'; my @data; my $record_count = 0; - $dbh->do("COPY $table TO STDOUT CSV HEADER;"); + $dbh->do("COPY $table TO STDOUT CSV DELIMITER E'\t' HEADER;"); 1 while $dbh->pg_getcopydata(\$data[$record_count++]) >= 0; open (my $eout, '>', $efile) or abort("Could NOT open $efile."); foreach my $d (@data) { @@ -203,7 +203,7 @@ sub export_table { sub die_if_gsheet_tracked_table_does_not_exist { if (!check_for_gsheet_tracked_table()) { - die "Table $MIGSCHEMA.gsheet_tracked_table does not exist. Bailing...\n"; + die "Table gsheet_tracked_table does not exist. Bailing...\n"; } }