SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 SQL Server 2008 Forums
 SSIS and Import/Export (2008)
 Import Excel Text via SSIS to sql table
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

khorkh888
Starting Member

Malaysia
4 Posts

Posted - 05/14/2012 :  03:21:40  Show Profile  Reply with Quote
Hey All Expertises,

I am facing problem to load a batch of text in Excel into sql table using SSIS. Here is in Excel look like:

Date KPI Plant Remarks
01-04 A 1 U3 not is down
01-04 B 1
02-04 A 2 L3 is down due to
1) no material
2) no schedule
3) waiting for vendor


As you can see, the Remarks column can have "enter" value. How to load all this into SQL table with same display as in Excel?

Help needed please. Thanks.

KKH

visakh16
Very Important crosS Applying yaK Herder

India
47069 Posts

Posted - 05/14/2012 :  23:18:57  Show Profile  Reply with Quote
are values still come under same cell or spanning over multiple cells?

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page

khorkh888
Starting Member

Malaysia
4 Posts

Posted - 05/15/2012 :  01:40:25  Show Profile  Reply with Quote
Hi Visakh,

There are total of 4 columns ( Date, KPI, Plant, Remarks). For Date, KPI & Plant is very simple. Each value is under it owns cell.
But for the Remakrs, it is description column. So, user able to input & hit the "Enter" key to get the multiple line within the same Cell.

Eg: This is only 1 record for

Date KPI Plant Remarks
---- --- ----- --------
02-04 A 2 1) No material
2) No schedule
3) waiting for vendor


Thanks for the help
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

India
47069 Posts

Posted - 05/16/2012 :  00:12:07  Show Profile  Reply with Quote
so all these lines should end up in same record in table?

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page

khorkh888
Starting Member

Malaysia
4 Posts

Posted - 05/16/2012 :  02:45:07  Show Profile  Reply with Quote

hi Visakh.


Yes. It should be in 1 record only.


Thanks.

KKH
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

India
47069 Posts

Posted - 05/16/2012 :  20:12:09  Show Profile  Reply with Quote
quote:
Originally posted by khorkh888


hi Visakh.


Yes. It should be in 1 record only.


Thanks.

KKH


is there a definite delimiter to indicate end of row?

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page

khorkh888
Starting Member

Malaysia
4 Posts

Posted - 05/23/2012 :  21:42:17  Show Profile  Reply with Quote
hi Visakh,

Actual is the CR/LF function at the end of the wrong.
Good news, I am able to load all the data in. Initailly, it was truncate after 255 character. So, I change it to unicode text. Now all record are loaded :-).

Thanks for the reply.

Regards .



KKH
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

India
47069 Posts

Posted - 05/24/2012 :  16:10:53  Show Profile  Reply with Quote
np
glad that you sorted it out!

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.08 seconds. Powered By: Snitz Forums 2000