Solved

Problems replacing aphostophies

Posted on 2012-04-13
3
475 Views
Last Modified: 2012-04-13
I was hoping that someone might help me understand why a problem I had importing data occurred and how I can resolve it if it happens in the future.

I was importing data using mySQL workbench and used MS Excel / MS Word to add apostrophes around the text before I imported it.  I then encountered an error when mySQL did not like one of the apostrophes.

(1,'Administrator',6,15,25,‘2012-04-13 00:00:00','1899-12-30 12:18:00','T Administrator')

Only the apostrophe before 2012-04 caused a problem but no matter what I replaced it with in Word, mySQL refused to accept it.  In the end, since I only had 50 records, I changed them all by hand to get the data import to work.

I would appreciate if someone could tell me what causes this behaviour and how to get around it.  Why would only one apostrophe be different – I originally added them all in MS Excel before saving the file in a .csv format, opening it in MS Word.

The steps I took were:
1)      added single quotes around some columns that contained data i.e. =”’” & C4 & “’”
2)      Copied column and pasted Values only
3)      Copied all columns into table in MS Word
4)      Converted table to text using commas as field break
5)      Replaced all paragraphs with ),( adding an initial opening bracket
6)      Copied into MySQL and made it into an Insert query
0
Comment
Question by:Nemetona
  • 2
3 Comments
 
LVL 76

Expert Comment

by:GrahamSkan
ID: 37843048
It looks like a "Smart quote" to me. This one is for opening speech. The closing version looks the same, but turned through 180 degrees.  Some software will treat it like an apostrophe, and some won't.
0
 
LVL 76

Accepted Solution

by:
GrahamSkan earned 500 total points
ID: 37843081
"Smart quotes" is Word's term to differentiate them from straight quotes. The default setting in Word's Autocorrect  is to substitute these angled versions whenever the user hits the single quote (apostrophe) or the double quotes keys.
"'
0
 

Author Closing Comment

by:Nemetona
ID: 37843214
I'm still not very sure why it only happened with the quote before the 2012 and none of the other ones.

By turning off the Autocorrect option to replace straight quotes with curly quotes the issue has gone away.

Many thanks.
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes how to use the Send to Mail Recipient command. The instructions apply generally to Office 2007 and later versions, but Microsoft® Word 2013 was used for the specific steps and figures.  What is Send to Mail Recipient? Send…
This code takes an Excel list of URL’s and adds a header titled “URL List”. It then searches through all URL’s in column “A”, looking for duplicates. When a duplicate is found, it is moved to the top of the list. The duplicate URL’s are then highlig…
Graphs within dashboards are meant to be dynamic, representing data from a period of time that will change each time the dashboard is updated with new data. Rather than update each graph to point to a different set within a static set of data, t…
In a previous video Micro Tutorial here at Experts Exchange (http://www.experts-exchange.com/videos/1358/How-to-get-a-free-trial-of-Office-365-with-the-Office-2016-desktop-applications.html), I explained how to get a free, one-month trial of Office …

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now