0

The sqlbulkcopy function works fine in my local environment but when I deploy it to IIS it only imports 17837 out of the 67K odd rows. Does anybody know what can cause this issue?

Brian Tompsett - 汤莱恩
  • 5,753
  • 72
  • 57
  • 129
Mohit
  • 115
  • 6
  • Update - If I Import a file with 145770 rows it imports 29996. So I'm confused, as there's no ratio or pattern with this data. – Mohit Jan 21 '13 at 22:45

1 Answers1

0

Actually the problem was with the Excel connection string I was missing the 'IMEX=1' at the very end. The correct connection string is - Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\uploaded.xlsx;Extended Properties='Excel 12.0 Xml;HDR=YES;IMEX=1'"

Mohit
  • 115
  • 6