Click here to Skip to main content
15,885,216 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
Greetings

Dear members, I've been checking out on internet, however, i didn't a single similar question, so i thought to ask it, may come handy for someone else, so here i go:

I have this giant excel files with 2 columns and +800,000 rows, the process is like this:
I am Filtering based on the second column(so there are many similar data on second columns), then after filter, i copy the first column and paste it on a notepad file(.txt) and change its name to second's column filter.
[Summery]
Input: Excel File
Output: multiple .txt files

if i do this by hand would take hours and hours, so i thought maybe you can point me into a right direction, then rest i do myself.

Thank you in advance,
Posted
Updated 25-Aug-15 14:14pm
v2
Comments
Sergey Alexandrovich Kryukov 25-Aug-15 19:30pm    
The expression "Notepad File" is ridiculous. This is nearly the same as saying "Microsoft's letter 'M'". :-)
Why having Excel at all, if you want to work with text file?..
—SA
Member 11734067 25-Aug-15 20:14pm    
Hey,
Well to be honest, i have lists of phone numbers and postal codes, as first and second columns, I'm trying to organize them, then upload them on my SQL Server, thought it would take ages to do it by myself, is it possible to write something in C# that can run it?
regards!
Sergey Alexandrovich Kryukov 25-Aug-15 21:19pm    
You see, converting Excel from text would not be a problem, but them you will need to process the text. To me, it smells like non-engineering attempts to get around the dead-ends of a regular non-engineering user: putting data in Excel, manual work, all that stuff. Is it something like that? Then "conversion" is not a decent solution, half-measure...
—SA
Member 11734067 25-Aug-15 21:56pm    
Well Thank you, although "conversion" about the details and insults is not a decent solution, indeed,

Anyone else have any solution, i am all yours,
regards.
Sergey Alexandrovich Kryukov 25-Aug-15 22:56pm    
Well, well...
—SA

1 solution

You could find plentiful of information anywhere. For example, you could use Microsoft.Jet: https://en.wikipedia.org/wiki/Microsoft_Jet_Database_Engine[^].

Here is one of the code samples:
https://social.msdn.microsoft.com/Forums/vstudio/en-US/a6ceb8be-b633-4fff-88e0-1692206e2db2/c-excel-to-text-conversion[^].

[EDIT] Another approach is using Microsoft.Office.Interop.Excel, and one more would be using Microsoft Open XML SDK. You will find plenty of code samples. [END EDIT]

But I'll repeat: what you are going to do with the text? It looks to me as a non-engineering approach, the attempt of getting a little further from the user-level manual work. The mere fact that someone put the huge amount of data in Excel, office personnel's tool, tell the tail. Please, nothing personal. I could be mistaken here, but your attempt to play the "insult" card only confirms that. If I'm mistaken, just explain that. Anyway, you got the "solution".

—SA
 
Share this answer
 
v3
Comments
PIEBALDconsult 25-Aug-15 23:08pm    
The JET engine is sooo last century... The ACE engine is all the rage today.
Sergey Alexandrovich Kryukov 25-Aug-15 23:12pm    
Well, whatever... Will you waste some more time on another solution. Don't you think that the "problem" is not exactly high-tech?.. :-)
And... see also update to the question, after [EDIT]...
—SA
Patrice T 25-Aug-15 23:32pm    
Agreeing on weird feeling.
Unless there is very good untold reasons to do things the way you are, it is highly suspicious.
The question is practising: Why make things simple when you can make them complicated ?
Sergey Alexandrovich Kryukov 26-Aug-15 1:42am    
Great comment, especially the last statement!
Did you see my post? Here: Unhappy Inquirer or Is the Abuse the Main Purpose of Programming?
—SA

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900