473,378 Members | 1,378 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,378 software developers and data experts.

Transferspreadsheet not importing some data

I have set up the following vba code:

DoCmd.TransferSpreadsheet acImport, acSpreadsheetTypeExcel9,
"Sheet1", _
"Z:\Accounting\DataArchive\Monthly_Database_Data\C opy of
NIGHTFILLS JUL 19.06.xls", True, "A1:F200"
The data to be imported is as follows:

Account B/S QTY Contract Px Ticket#
83183979 B 2 GCQ 6333 32
12916393 B 2 GCQ 6305 400
12917937 S 2 GCQ 6330 20
63148781 S 3 SIN 10585 526
37532141 B 3 CLQ 7390 534
83083127 S 2 GCQ 6325 5
47847810 B 2 NGU 5750 440
83083128 B 20 SIU 10550 4
84947002 S 1 GCQ 6283 313
58990000 B 1 SIU 10535 528
20754623 S 10 SIU 10535 744
68041247 S 10 GCQ 6310 520
83388252 S 1 GCQ 6372 609
20754623 S 6 GCQ 6310 743
20754623 S 4 GCQ 6308 743
20555308 S 2 GCQ 6305 745
63148781 B 4 SIU 10540 516
74761005 S 2 SFU 8021 30
46105806 S 2 ESU 124475 443
93293205 S 1 SPU 124520 19
14160000 B 3 ESU 124500 384
14160000 B 5 ESU 124450 385
14160000 B 5 ESU 114475 11
86020177 B 1 CDU 8816 27
11911905 B 1 YMU 10867 33
46015880 S 1 ZCZ 2632 25
46060485 S 1 ZSQ 5880 402
46060485 S 2 ZSQ 5876 402
477OBK50 S 1 YMU 10862 31

The problem is that the 477OBK50 is not imported (the rest of the row
comes through fine). Now comes the puzzling part. If I move the data in
row 30 to row 26 the row comes through just fine. If the row with the
477OBK50 data in is placed anywhere after row 26 the 477OBK50 is
missing. BTW, the table that it is imported into is all text set at 255
character size for each field. When the data is imported in and the
477OBK50 is missing there is an import error table that reads this:

Error Field Row
Type Conversion Failure Account 30

Can anyone shed any light on what the problem might be? Any and all
help is appreciated. Thanks.

Dave Christman

Jul 19 '06 #1
1 4004
When doing the transferSpreadsheet, Access will scan down a number of
records to determine how to characterize the field. If it looks at
(say) 29 rows and they are all numeric then it will define that column
as numeric. If it finds an alpha in the column in that number of
records it will say that the field is a text field.

I have had to go to the extent of adding a dummy row (row 2) in a
spreadsheet in order to help the system classify the column properly.

I believe that there is a registry setting that can be set to tell it
how many rows to read for the classification. I have been hesitent of
playing around in there, so I added the automation step of opening
excell from Access and adding the row.

Ron

Jul 19 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Nathan Bloom | last post by:
Hi, I have a procedure that transfer data from an Excel spreadsheet to an Access 2000 table. There is a start date and an end date in the range specified. One of the date fields transfers...
3
by: Randy Harris | last post by:
I'm using TransferSpreadsheet to transfer data from A2K to an Excel spreadsheet that has some pivot tables in it. It seems like it is working, but when I open the spreadsheet, it gets an error...
1
by: barma16 | last post by:
I've hit a bit of a brick wall here, and could use some advice. I have an Access application whose output is a four-tab Excel spreadsheet where three of the four tabs are the result of database...
4
by: Tom Louchbaum | last post by:
I try to use this command to import a spreadsheet "DoCmd.TransferSpreadsheet acImport, 8, tablename & " -tbl", DIR & "Book2.xls", True" and it errors out. If I try to import that same...
8
by: bob almady | last post by:
I am using MS Access 2000. I have an application that Imports different spreadsheets from a MS Excel 2000 workbook that exists on the network. When I run the application on 2 of the pcs, the...
2
by: Quique | last post by:
Hello, I've got a problem importing a worksheet Excel into a temporary table in access. All the information is imported but the table is not ordered as it is originally in excel. I'm using a...
5
by: D.Stone | last post by:
I'm getting a problem with importing an Excel spreadsheet into a table in a SQL Server 2000 back-end. I'm doing this in VBA in an onClick event proc in an Access 2003 project. The target table's...
3
by: Icarus | last post by:
I'm using TransferSpreadsheet to import an Excel file in to MS Access 2003. DoCmd.TransferSpreadsheet acImport, 8, strTable, strFileName, True, "" One of the columns in the Excel file is a...
4
by: ambmil | last post by:
I am using transfertext and transferspreadsheet in VBA to import an excel file (.csv or .xls) into access 2003. Some of the fields are failing (I am getting an import error file), but I am not...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.