ZIP column from spreadsheet wrong database type
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
openoffice.org (Ubuntu) |
Invalid
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: openoffice.org
Was creating a newsletter in OpenOffice in Feisty. I typed the 154 rows into a table in Writer for ease of editing, but when it came time for merging, I needed to convert the data before I could register the data in the database component (unlike MS Word, which can mail merge using a Word document table as a data source).
I exported the table to a tab-delimited text file, and I imported the data into an OpenOffice spreadsheet page using the Insert--> Sheet from File function. The spreadsheet was created correctly. To be certain of my source, I deleted all the empty sheets, leaving the imported one (and renaming it to Sheet1 from the name the imported sheet had been given).
When I registered the spreadsheet file as a data source for print merging in Open Office, all of the columns came across correctly EXCEPT the ZIP column. The source file AND the resulting spreadsheet contained a mixture of seven-digit and nine-digit zip codes.12345-1234 vs 12345 (The first row contained the seven digit ZIP 74133.)
When I merged the documents, all of the nine-digit ZIP codes became NULL, leaving only the five-digit ZIP codes, -- it turns out the database had assigned the ZIP column to the INTEGER data type, rather than a string data type as it had all of the other columns. I could find no way using any of the database tools to change the data type assignment. The data still existed in the original spreadsheet, but the database only passed on the five-digit ZIP codes on to the mail merge.
My workaround was to export the data to tab-delimited data, and then point to THAT file directly in the Address Data Source Wizard. The tab-delimited text data imported correctly (but makes a lousy source file for address maintenance purposes).
Actually to be slightly clearer -- the nine-digit ZIP codes were NULL when you looked at them in the Data Sources table from within Writer -- they were gone even before attempting the merge process, but of course that's when I noticed them missing.