Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Importing from excel
Message
From
03/03/2016 11:56:06
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
 
 
To
03/03/2016 07:42:58
General information
Forum:
Microsoft SQL Server
Category:
Import/Export
Miscellaneous
Thread ID:
01632475
Message ID:
01632491
Views:
31
>HI
>
>I'm importing to sql from some spreadsheets.
>
>I'm saving the data as tab delimited as going straight from the excel sheet was causing many issues.
>
>My problem is that some data cells contain a lot of text. This displays ok in excel with formatting new lines etc. But when I save as tab delimited all that formatting is lost and I wanted to save each line a s a separate note.
>
>Any ideas on how I can save that formatting or split up the text. (here's an example with formatting )
>
>26/02/16 JP RE said get surveyor or Steve to inspect and report back.
>25/02/16 JP Emailed KM to ask if the fencers have put in their report
>25/02/16 JP Kerrie emailed: cannot re-band if council say no. Her best chance is MX and there's a 2 bed ground floor flat in xxxx she could go for. Kerrie suggested speaking to Jemma or Sally as they'll know her band and where's she's coming on the bidding list.
>
>
>Any way I can split on the date string pattern ?

The same old problem of data and metadata being mixed up in a text file - whatever you set as a delimiter may end up as content, and the exporting utility doesn't care about that, it has successfully created an export file. That the file contains separators and/or delimiters inside a text field, the exporter doesn't care - and the importer is screwed.

In most of the excel exports I've found that line breaks are LF characters inside the fields, while the CR is used as record delimiter. Perhaps this may help... at least help to write a .prg which would import the tab delimited file into a cursor and then send the results of that cursor into a sql-side table. That's what I regularly do, and actually have a ready library of things which help in the process. When I hear "import from excel sheet" I don't even bother with any attempts to do a straight import.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Reply
Map
View

Click here to load this message in the networking platform