Log in
::
Register
::
Not logged in
Home
Tags
Articles
Editorials
Stairways
Forums
Scripts
Videos
Blogs
QotD
Books
Ask SSC
SQL Jobs
Training
Authors
About us
Contact us
Newsletters
Write for us
Recent Posts
Recent Posts
Popular Topics
Popular Topics
Home
Search
Members
Calendar
Who's On
Home
»
SQL Server 7,2000
»
Administration
»
DTS to import Data from excel
DTS to import Data from excel
Rate Topic
Display Mode
Topic Options
Author
Message
river1
river1
Posted Tuesday, February 19, 2013 2:44 PM
Say Hey Kid
Group: General Forum Members
Last Login: Tuesday, May 07, 2013 6:56 AM
Points: 679,
Visits: 953
Hi,
I have one excel that has data like this:
ADM14021360066,208930705 502151 Abraçadeiras Plasticas Wurth 280x4,8 UN 1000.1 NOVO 200 Camião
ADM14021360066,208930706 502161 Abraçadeiras Plasticas Wurth 360x4,8 UN 1000.1 NOVO 300 Camião
ADM14021360066,208930707 2 Barra Reparação Magnum UN 1000.1 NOVO 2 Camião
ADM14021360066,208930708 3 Bicos Cola UN 1000.1 NOVO 70 Camião
ADM14021360066,208930709 4 Bidon Limpeza Travões Wurth 20Lt UN 1000.1 NOVO 1 Camião
ADM14021360066,208930710 7 Clip Autocolante UN 1000.1 NOVO 64 Camião
ADM14021360066,208930711 147334 Cola Fernador Azul Berner UN 1000.1 NOVO 1 Camião
ADM14021360066,208930712 147321 Cola Fernador Verde Berner UN 1000.1 NOVO 1 Camião
ADM14021360066,208930713 89309 Cola Klebfix Wurth UN 1000.1 NOVO 2 Camião
ADM14021360066,208930714 81 Cola Loctite Preta UN 1000.1 NOVO 1 Camião
ADM14021360066,208930715 0893449f Cola Metal Liquido Wurth1 UN 1000.1 NOVO 1 Camião
ADM14021360066,208930716 4242 Cola Past-o-Fix Berner UN 1000.1 NOVO 0 Camião
ADM14021360066,208930717 8963092f Cola Plastofix Wurth UN 1000.1 NOVO 2 Camião
There are several values that are imported as null on column codigo.
For instance, the code that is on excel as 8963092f is imported to the column codigo as null.
Can someone explain why?
thanks,
Pedro
P.S table code:
CREATE TABLE [dbo].[table2] (
[STSTAMP] [char] (25) COLLATE Latin1_General_CI_AS NULL ,
[CODIGO] [varchar] (1000) COLLATE Latin1_General_CI_AS NULL ,
[DESIGNACAO] [varchar] (1000) COLLATE Latin1_General_CI_AS NULL ,
[UNIDADE] [varchar] (1000) COLLATE Latin1_General_CI_AS NULL ,
[FAMILIA] [varchar] (1000) COLLATE Latin1_General_CI_AS NULL ,
[ESTADO] [varchar] (1000) COLLATE Latin1_General_CI_AS NULL ,
[QUANTIDADE] [varchar] (1000) COLLATE Latin1_General_CI_AS NULL ,
[LOCALIZACAO] [varchar] (1000) COLLATE Latin1_General_CI_AS NULL
) ON [PRIMARY]
GO
Post #1421860
Evil Kraig F
Evil Kraig F
Posted Wednesday, February 20, 2013 1:37 AM
SSCertifiable
Group: General Forum Members
Last Login: Thursday, June 13, 2013 6:44 PM
Points: 5,720,
Visits: 6,192
Excel importing is insanely fussy and nearly impossible to remotely troubleshoot, but I'll try a bit. What's the import designation for that field? VARCHAR(255) or VARCHAR(MAX)? Is it possibly int or something else?
Must you import from excel or can you have your users save the files as CSVs? They can do that right from Excel when they're done fussing with the file.
- Craig Farrell
Never stop learning, even if it hurts. Ego bruises are practically mandatory as you learn unless you've never risked enough to make a mistake.
For better assistance in answering your questions
|
Forum Netiquette
For index/tuning help, follow these directions.
|
Tally Tables
Twitter: @AnyWayDBA
Post #1421972
river1
river1
Posted Wednesday, February 20, 2013 3:20 AM
Say Hey Kid
Group: General Forum Members
Last Login: Tuesday, May 07, 2013 6:56 AM
Points: 679,
Visits: 953
Dear Craig,
Thanks.
I have converted the file to CSV and it works.
Post #1422006
Evil Kraig F
Evil Kraig F
Posted Wednesday, February 20, 2013 10:35 AM
SSCertifiable
Group: General Forum Members
Last Login: Thursday, June 13, 2013 6:44 PM
Points: 5,720,
Visits: 6,192
Glad that the workaround is effective for you. Excel and its data drivers tend to be... aggravating to work with. Good luck!
- Craig Farrell
Never stop learning, even if it hurts. Ego bruises are practically mandatory as you learn unless you've never risked enough to make a mistake.
For better assistance in answering your questions
|
Forum Netiquette
For index/tuning help, follow these directions.
|
Tally Tables
Twitter: @AnyWayDBA
Post #1422203
« Prev Topic
|
Next Topic »
Permissions
You
cannot
post new topics.
You
cannot
post topic replies.
You
cannot
post new polls.
You
cannot
post replies to polls.
You
cannot
edit your own topics.
You
cannot
delete your own topics.
You
cannot
edit other topics.
You
cannot
delete other topics.
You
cannot
edit your own posts.
You
cannot
edit other posts.
You
cannot
delete your own posts.
You
cannot
delete other posts.
You
cannot
post events.
You
cannot
edit your own events.
You
cannot
edit other events.
You
cannot
delete your own events.
You
cannot
delete other events.
You
cannot
send private messages.
You
cannot
send emails.
You
may
read topics.
You
cannot
rate topics.
You
cannot
vote within polls.
You
cannot
upload attachments.
You
may
download attachments.
You
cannot
post HTML code.
You
cannot
edit HTML code.
You
cannot
post IFCode.
You
cannot
post JavaScript.
You
cannot
post EmotIcons.
You
cannot
post or upload images.
Copyright © 2002-2013 Simple Talk Publishing. All Rights Reserved.
Privacy Policy.
Terms of Use.
Report Abuse.