Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Importing from Excel
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Importing from Excel
Miscellaneous
Thread ID:
01130272
Message ID:
01130272
Views:
56
I have a situation where I was importing data from an Excel spreadsheet and it worked fine. I created the cursor to import to by doing a SQL Select from another table, taking some of its fields as is and adding a COST field. The spreadsheet format matched the table format. Worked like a champ. Then I said "Hey, if you add these other two fields to your spreadsheet, we can do so-and-so" to which the client agreed. So they just tacked the two columns on to the spreadsheet (a 5 column spreadsheet became a 7 column spreadsheet) and I tacked the same two columns on to the end of the table I'm using for the import. And now the import is screwed up. The first column, part number c(12), is not coming in at all - it's just blanks. The two new fields are also not being populated.

Here's the code:
select partnum, list_price, dlr1_price, exp1_price, 00000.00 as cost,;
       classid, descr;
   from parts;
   where .f.;
   into cursor NewPrices readwrite
append from "2006 Parts.xls" type xl8
In the previous code (and spreadsheet), the CLASSID and DESCR fields did not exist. Now they do and the data is not imported as expected. Anybody seen anything like this?

Russell Campbell
eCost.com continues to rip people off
Check their rating at ResellerRatings.com
Next
Reply
Map
View

Click here to load this message in the networking platform