I have a problem with CSV file.I have a text Contacts file
like
that+923334897142+923334897143+923334897144+923334897145+923334897146+923334897147+923334897148when
I am converting this text file in to CSV file, then CSV file Show my numbers
without +
example 923334897142923334897143923334897144923334897145923334897146923334897147923334897148
I want my all numbers with + in to csv file, I am using total CSV converter. or
if any program that convert my Text file direct in to Vcf, Vcard file, then
inform me. (Window 7 - office 2007)
This is an example of what the line should look like:
"=""+923334897142"""
See this as a reference:
https://superuser.com/questions/318420/formatting-a-comma-delimited-csv-to-force-excel-to-interpret-value-as-a-string
Related
We have a .txt file with encoding UTF-16 LE (discussed here, as well). We need to load this file into an Azure SQL database. We are first trying to convert this file to a csv format by using Text Import Wizard of Data Excel 365 wizard. But if we use the ^|^,^|^ as a custom delimiter, the first and last columns still end up with ^|^ value.
Question: What may be possible solutions/work arounds for converting this type of file to csv?
Remarks: This is a huge file (1GB) with about 150 columns. Following is just a sample for explaining the scenario in this post.
Sample of the txt file:
^|^Col0^|^,^|^Col1^|^,^|^Col2^|^,^|^Col3^|^,^|^Col4^|^,^|^Col5^|^,^|^Col6^|^,^|^Col7^|^
^|^1234^|^,^|^4600869848^|^,^|^6000.00^|^,^|^2021-12-20 10:16:19.3600000^|^,^|^False^|^,^|^^|^,^|^^|^,^|^2^|^
^|^5431^|^,^|^3425143451^|^,^|^30000.00^|^,^|^2021-12-13 10:27:44.9030000^|^,^|^False^|^,^|^^|^,^|^^|^,^|^2^|^
.....................
............................
After using the delimiter ^|^,^|^ in Excel text import wizard
Instead of mentioning the ^|^,^|^ as custom delimiter, you can mention comma as a delimiter, that will give you a result like below:
Then you can record a macro to replace the desired characters which is ^|^ after importing is done as mentioned in below link:
Create A Macro Code To Achieve Find And Replace Text In Excel
I have txt file which has 1400 columns and 3.1M rows.
I want to convert this file into csv.
I tried doing it from excel - Data - from text option.
The file was made but it had only 120k rows and all 1400 columns.
I am not sure how i should convert this whole file into csv?
It would be great to have help on this.
Thanks
I see you selected "notepad" tag. You should try: gVim ( https://gvim.en.softonic.com/ ). I used it to open 2gb files and it worked like a charm.
You can find more programs that allow you to open big files here: https://stackoverflow.com/a/159537/1564840
On the other hand, I suggest you to split that big txt file in multiple txt files. Then you can convert the smaller txt files one by one.
I am trying to load the following simple csv file into tableau public 9.3:
customers,item1,item2,item3,item4
1,0,0,0,0
2,0,0,0,0
3,0,0,0,0
However, it doesn't read the file as separate columns, despite the field separator being Comma. Instead it treats the whole line as one column. Any help would be greatly appreciated :
If you change your locale settings to English US you will be able to load the file. You should also be able to work around this by creating a schema.ini file.
Go to Data > Manage fields > [Field] Options
You can also control imported CSV behavior post import both by splitting individual columns (which will remain split on update as well), or by the image below at the CSV level.
That doesn`t work for me. So I reopen the .csv file in Excel and save it again in .csv format with ',' as the delimeter.
After that my file looks like .csv with ';' delimeter and works with Tableau.
I am importing some thousands lines of Data from a .txt file containing two columns and the format is as it follows:
A8041550408#=86^:|blablablablablablablablablablablablablablablablablablablabla1
blablablablablablablablablablablablablablablablablablablabla2
blablablablablablablablablablablablablablablablablablablabla3
A8041550408#=86^:|blablablablablablablablablablablablablablablablablablablabla1
blablablablablablablablablablablablablablablablablablablabla2
A8041550408#=86^:|blablablablablablablablablablablablablablablablablablablabla1
blablablablablablablablablablablablablablablablablablablabla2
blablablablablablablablablablablablablablablablablablablabla3
blablablablablablablablablablablablablablablablablablablabla4
etc....
What I have done so far is create a table with the two fields, but when i try to import the .txt file as a CSV and putting / Columns separated By : | /, I get an error:
"Invalid column count in CSV input on line 2."
Which is quite obvious since the second line of the .txt file is empty.
Moreover, I have tried importing the file as a CSV using LOAD DATA, and it didn't work as well it has just filled up the table with random words and phrases from the .txt file .
So my question is : How can I import the data from this file ?
You have to fix your file; in its current state you cannot expect the import module to be able to understand it. First step would be to remove the empty lines: How to remove blank lines from a Unix file
I have a semicolon-separated csv file over here, and I would like to be able to look at it with gnumeric. Sadly, gnumeric does not read the semicolon as a separator.
I have tried:
appending sep=; on the first line
clicking through the GUI menus
using sed to replace the semicolons with commas (sadly, that leads to breakage, since by document occasionally uses commas within cells
What else can I do?
In recent versions of gnumeric a new Import Data tool is available. To launch the tool choose Data|Import Data|Import Text File... from the menu.
In the Import Data File dialog choose your file and hit Open.
In the next screen select Separated format and click Forward
In the following screen select a separator from a number of available options and click Forward once again to choose the columns to import.
Click Finish to complete.
Solution that worked for me in a comma separated csv file with dot decimal separators:
Open .csv file from a text editor
replace all "," with ";" (semicolon)
replace all dot decimal separators "." with ","
save file
open gnumeric, go to Data -> Get External Data -> Import Text File
and then open the saved file
hit Forward and Finish
save as a gnumeric file