Hi, I can't seem to find out to fix this issue...I have my spread sheet set up with all columns needed, my only issue is, when I save it as a text file, it adds quotations " " and also adds to much space between each column, so when I dump it on the DB, I get errors...As I read around on the net, I found that I can open the text file in word and find and replace all quotations and it's done quickly, but I still have the issue with the spacing..I used an add-in for triming the columns to remove spacing, but doesn't seem to work..Here is an example of what it looks like: See, too much space is added....Can anyone please guide me in the correct direction on how to fix this?...Thanks.
INSERT INTO `PLD_LINK` (`url`, `title`, `description`, `status`, `LINK_TYPE`, `RECPR_REQUIRED`, `category_id`) VALUES (http://www.testeter.com/ , Test , Retained search test , 2 , 0 , 0 , 1339 );
Can you not go into the Db and inthe table catagory right click and choose Import Table, this will allow you to directly import it in.
The other way I guess is when you save the spredsheet, instead of a text file, why not a CSV file?
Hi, I tried previously to import it directly in the DB but I get errors....
"Invalid field count in CSV input on line 1."
I don't know if it has to do with the CSV options in the DB..They are set to the below:
Replace table data with file "Not checked off"
Ignore duplicate rows "Not checked off"
Fields terminated by ;
Fields enclosed by "
Fields escaped by \
Lines terminated by auto
Column names "Left Blank"
My spread sheets has all the " ; \ already in separate columns..
Thanks..
Last edited by mike77; 03-06-2010 at 06:16 PM.
I guess in this instance without seeing the Db and files in question it will be very hard to tell.
Your post does not comply with Rule 1 of our Forum RULES. Your post title should accurately and concisely describe your problem, not your anticipated solution. Use terms appropriate to a Google search. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will be addressed according to the OP's experience in the forum: If you have less than 10 posts, expect (and respond to) a request to change your thread title. If you have 10 or more posts, expect your post to be locked, so you can start a new thread with an appropriate title.
To change a Title on your post, click EDIT then Go Advanced and change your title, if 2 days have passed ask a moderator to do it for you.
I have edited it for you
Hope that helps.
RoyUK
--------
If you are pleased with a member's answer then use the Star icon to rate it, if you are pleased enough to part with cash consider a donation to Children in Need
For Excel consulting, free examples and tutorials visit Excel Consulting-Excel VBA
Check out the free Excel Toolbar
New members please read & follow the Forum Rules
Remember to mark your questions Solved and rate the answer(s)
Code Tags: Make your code easier for us to read
Last edited by mike77; 03-09-2010 at 02:54 AM.
OK, so thats a txt file, what about a CSV file?
If the data isnt to sensitive can you up load both Db and XL sheet?
Additianlly I'd suggest reading royUk's comments.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks