+ Reply to Thread
Results 1 to 9 of 9

How to convert imported data to a table while preserving external connections

  1. #1
    Registered User
    Join Date
    10-18-2017
    Location
    USA
    MS-Off Ver
    2016
    Posts
    5

    Question How to convert imported data to a table while preserving external connections

    I am new to this forum and this is my first post. So please bear with me if my question has already been addressed elsewhere, as I expect it to be a fairly common issue. I have imported a csv file as an Excel (version 2016) range via "Data->From Text" option, and now trying to convert it to a table. But I always get "Your selection overlaps one or more external data ranges. Do you want to convert the selection to a table and remove all external connections?" Choosing "No" does not give me the table, but I do not want to say "Yes", because I'd like to keep this connection, so I can use "Refresh All" to quickly incorporate any future changes to the original csv file into all subsequent charts etc I create using this table.

    Thanks,
    Manojit

  2. #2
    Forum Expert CK76's Avatar
    Join Date
    06-16-2015
    Location
    ONT, Canada
    MS-Off Ver
    MS365 Apps for enterprise
    Posts
    5,973

    Re: How to convert imported data to a table while preserving external connections

    Instead of using "Data->From Text".

    Use "Get & Transform -> From File ->From csv"

    It uses powerquery to bring in data, and then do transformation as needed using M (or GUI). Once done, result can be loaded to sheet as table or as data model for analysis using PivotTable.

    Edit: It will retain connection and load as table.
    "Progress isn't made by early risers. It's made by lazy men trying to find easier ways to do something."
    ― Robert A. Heinlein

  3. #3
    Registered User
    Join Date
    10-18-2017
    Location
    USA
    MS-Off Ver
    2016
    Posts
    5

    Re: How to convert imported data to a table while preserving external connections

    Thanks for the quick reply!

  4. #4
    Forum Expert
    Join Date
    10-02-2014
    Location
    USA
    MS-Off Ver
    2016
    Posts
    1,222

    Re: How to convert imported data to a table while preserving external connections

    If your importing this into a new blank file just hit yes. It seems more likely you are trying to import it into an existing sheet, in which case you likely have content on the sheet that refers to an outside data source in some fashion (named range, conditional format, hyperlink, invisible content, etc).

    The csv itself isnt the data connection, its some content that Excel perceives as already being in the destination that the imported content will go. This usually means it doesnt matter what you try to put in those cells or how, you would still destroy whatever was there, warning or not.

    The other option would be to open the csv with Excel as a seperate file and copy/paste to your desired destination.

  5. #5
    Registered User
    Join Date
    10-18-2017
    Location
    USA
    MS-Off Ver
    2016
    Posts
    5

    Re: How to convert imported data to a table while preserving external connections

    Thanks. I was importing into a new sheet (not existing one), but I was wondering what if later new data get appended to the end of the original csv file - would it update my table etc by hitting Refresh all.

  6. #6
    Forum Expert
    Join Date
    10-02-2014
    Location
    USA
    MS-Off Ver
    2016
    Posts
    1,222

    Re: How to convert imported data to a table while preserving external connections

    Quote Originally Posted by manojit View Post
    Thanks. I was importing into a new sheet (not existing one), but I was wondering what if later new data get appended to the end of the original csv file - would it update my table etc by hitting Refresh all.
    This only happens when you create a link to external data and in my experience doesnt work so great when working off a text file like csv. Depending on where the csv comes from you may consider skipping the csv alltogether and just connecting your Workbook direct to the database/source of the csv if thats possible with your data/source.

    Alternatively, if the layout of the columns doesnt change from csv to Workbook, you could simply copy CSV content and paste it below the current data (presuming you opened CSV in Excel as a seperate file).

  7. #7
    Registered User
    Join Date
    10-18-2017
    Location
    USA
    MS-Off Ver
    2016
    Posts
    5

    Re: How to convert imported data to a table while preserving external connections

    Thanks again. I am somewhat new to Excel, and these posts are quite helpful. As a background to my question, I am working on an assignment that starts with importing a set of csv data into excel tables, and using them to build a dashboard that contains several charts & tables. This dashboard needs to be flexible (dynamic?) so that if new rows get added to any of the original csv files - for example, a client sends updated sales data every few months - I should be able to update the dashboard just by hitting "Refresh All", if at all possible, instead of having to re-work it from the ground up. This is why I wanted to know what is the best way to import the csv data so external connections to them are preserved.

  8. #8
    Forum Expert CK76's Avatar
    Join Date
    06-16-2015
    Location
    ONT, Canada
    MS-Off Ver
    MS365 Apps for enterprise
    Posts
    5,973

    Re: How to convert imported data to a table while preserving external connections

    The method outlined in my post will create connection to CSV and will apply any transformation steps to subsequent import.

    If the same file is being updated, so will imported table when you refresh. Along with all appropriate transformations.

    For an example...
    I have dashboard set up connecting to CSV file stored in OneDrive, which is updated from data sent from cloud based CRM to email (unfortunately no direct DB access). MS Flow is used to store attachment to specific folder within OneDrive. PQ then queries the file and imports it into data model for consumption by PowerPivot.

  9. #9
    Registered User
    Join Date
    10-18-2017
    Location
    USA
    MS-Off Ver
    2016
    Posts
    5

    Re: How to convert imported data to a table while preserving external connections

    Thanks. Yes, I used your Powerquery method to import the data.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Security Warning: External Data Connections
    By danielexcelvba in forum Excel General
    Replies: 8
    Last Post: 07-19-2017, 09:16 AM
  2. [SOLVED] Work in connections with external data
    By kiluwa99 in forum Excel General
    Replies: 3
    Last Post: 06-28-2016, 01:03 AM
  3. external data connections are not refreshing even with VBA
    By krishna2221 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-07-2014, 04:00 AM
  4. When are External Connections not QueryTables?
    By apolloni in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-07-2013, 08:11 AM
  5. external data - cleanup existing connections
    By edstevens in forum Excel General
    Replies: 1
    Last Post: 04-26-2013, 12:03 PM
  6. Replies: 0
    Last Post: 01-28-2013, 04:35 PM
  7. Pulling Data from unopened Excel Spreadsheets with external connections
    By nschneemann in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 03-04-2010, 11:26 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1