Forum Discussion
Excel jamming and reformatting downloaded data:
ivraq Not sure I follow, but you seem to open a CSV file by simply double-clicking it. It defaults to be opened by Excel, where all the data is neatly split in cells based on the commas found in the raw data.
Once done, you need to save the file as an Excel workbook (.xlsx) to preserve the data in rows and columns. The "loss of data" message will not show anymore when you open the XLSX file.
By the way, the dates in the CSV file seem to be US style (d/m/y) but your Excel, apparently, is set to recognise European style dates (d/m/y), as 1/17/1977 gets transformed to a text as it is not recognised as a valid date. On the other hand, 3/9/1981 is seen as a date 3rd of September. But, most likely, the intended date is the 9th of March. Best to go through "Get external data", Text on the Data ribbon. Follow the steps in the Text import wizard. In step 3 of 3, select the correct "format" for the dates to be imported. In your case MDY.
- Ivoya15Dec 09, 2020Copper Contributor
Did not seem to support inserting of pictures yesterday. Anyways, in the background the file is opened in Microsoft Excel, while in the foreground it is opened in google sheets. Google sheets presents the data correctly. It seems the rows are "squished" together in Excel.
- Riny_van_EekelenDec 09, 2020Platinum Contributor
Ivoya15 OK. In Excel, on the Data ribbon, you'll find an icon "Text to columns". Follow through the steps:
Step 1) Delimited
Step 2) Comma
Step 3) In the Data preview, you'll see the columns that will be created. Most of the time Excel will guess the data type correct, but dates are alway a problem. Select the first column in the preview and set the Column data format to "Date: MDY".
Now press Finish and you should get a table similar to the one you see in Google sheets, but with correct dates.
- ivraqDec 09, 2020Copper Contributor
Riny_van_Eekelen Thank you so much! I barely use Excel; I usually load .csv into python/pandas directly, but here it was ment for Tableau. Apparently Excel by default had the delimiter not set to comma, and in turn also affected this inside Tableau. Look much better now