Bottom Line: Save time and effort cleaning up exported data in Excel with these tips for both manual adjustments and automated transformations using Power Query.
Skill Level: Intermediate
Watch the TutorialWatch on YouTube & Subscribe to our Channel
Download the Example FileFollow along with the same workbook used in this post.
Register.xlsxDownload Cleaning Up Exported DataExporting data from systems like QuickBooks can leave you with messy spreadsheets that require cleanup before analysis. In this post, we’ll cover step-by-step techniques for cleaning data manually and show how you can use Power Query to automate the process, saving you time and effort. First, let's look at cleaning up data manually.
Manual Data CleanupWhen cleaning up exported data manually, start by identifying common issues like merged cells, improper formatting, and inconsistencies in data types. Here are some practical steps:
1. Handling Merged Cells and Tabs Unmerge cells: Select the merged cell, then go to Home > Merge & Center to unmerge it. * Use Text to Columns: For text with tabs, colons, or other delimiters, use Data > Text to Columns* to split it into separate cells.
2. Converting Dates Stored as TextSome exported dates may look like dates but are stored as text. Convert them to date format using this trick:
Ctrl + H for Find and Replace, and replace the date delimiter (e.g., “/”) with itself. This forces Excel to reevaluate the data in the cells and recognize the values as dates.3. Fixing Numbers Stored as TextNumbers exported as text may cause issues with formulas or lookups. To convert them, select the column, click the Error Box at the top, and choose Convert to Number.
4. Formatting and Adjusting Column Heights Remove inconsistent row heights caused by wrapped text by selecting all cells, toggling Wrap Text* twice, and then autofitting column widths. * Adjust the font size and type for better readability (e.g., increase to size 11).
5. Splitting Sub-AccountsIf a column contains sub-accounts separated by colons (or other delimiters):
Automating Data Cleanup with Power QueryManual cleanup works, but when dealing with frequent exports, automation is a game-changer. Power Query can automate repetitive steps, ensuring consistent results every time.
1. Load the Data into Power Query Starting with a blank workbook, go to Data > Get Data > From File > From Workbook*, select your exported file, and open it in Power Query. You'll see your data in the Power Query Editor, like this:
2. Transform the DataPerform the following transformations in Power Query:
3. Save and Load Cleaned DataOnce your transformations are complete, choose Close & Load to output the cleaned data to a new sheet.
4. Automate with RefreshFor recurring tasks, save the Power Query steps:
Alt + F5).If you could use some help with learning Power Query, Here are three resources:
ConclusionCleaning up exported data doesn’t have to be a time-consuming task. Whether you prefer manual adjustments or automated workflows with Power Query, these techniques ensure your data is ready for analysis in no time.
Which cleanup method works best for you? Leave a comment below and share your experience!
Link to post: Mastering Data Export Cleanup in Excel