LibreOffice Calc · References and calculation · Intermediate
Insert and refresh a linked external data table
Insert and refresh a linked external data table. A controlled example with expected outcomes, changed-input checks and recovery.
Documentary author review; no native application testing claimed · Editorial standards
Use Sheet > External Links to insert a linked table from a source workbook. The source must expose a named range or database range: an ordinary rectangle of populated cells is not enough for this dialog.
Prepare a named source table
This exercise targets LibreOffice Calc 26.2 desktop, English standard menus, on Windows or Linux. The procedure is checked against the guide, not executed in a native application. Use two local ODS practice files so website availability and sign-in do not obscure the linking mechanism.
In StockSource.ods, put Item and Quantity in A1:B1. Enter Bolts, 10 in row 2 and Washers, 20 in row 3. Define a named range StockTable referring to A1:B3, then save the source. If you need the naming controls, follow named and database ranges. The name must include the header and both records.
Create StockReport.ods and leave A1:B10 empty. Put a separate check label in D1 and =SUM(B2:B3) in D2. This check is deliberately outside the linked area. Its baseline will be 30 after the import.
Insert the linked range
- Select A1 in StockReport as the upper-left destination.
- Choose Sheet > External Links.
- Browse to StockSource.ods, or enter its location and press Enter so Calc reads the available ranges.
- In Available Tables/Ranges, select StockTable. Selecting a range enables OK.
- Leave periodic refresh disabled for the first test, so updates are deliberate.
- Confirm. Check the two headers, both item names, quantities 10 and 20, and D2=30.
The dialog supports other source types, including HTML and CSV, but their import options differ. An HTML page with scripts or a login is not necessarily an importable table. A list with no names from an ODS source means you should fix and save the source’s named/database range, not select an arbitrary blank entry.
Refresh a changed value
Change the source quantity for Bolts to 14 and save StockSource. In StockReport, choose Edit > Links to External Files, select the source link and update it. Expect B2=14, B3=20 and D2=34. If the report still shows 30, inspect whether the source was saved, whether the link points to the intended file, and whether an update prompt was declined.
A linked area is not a safe place for independent annotations or manual corrections. A refresh can replace imported content. Keep comments, extra calculations and review notes outside the imported rectangle, preferably on a separate report sheet when the table may expand.
Distinguish changed data from changed range
Adding a new source record is a separate test. Enter Nuts, 6 in A4:B4 and expand StockTable to A1:B4 in the source; save. Refresh the destination and check that the third record appears. Update the independent check to =SUM(B2:B4), which should give 40. Merely adding row 4 without expanding a fixed source name does not make that row part of the linked table.
Leave ample blank space around the destination before expanding. If another calculation occupies the growth area, move it first or reinsert the link on an empty sheet. Do not accept overwritten neighboring work as normal maintenance.
Save and troubleshoot deliberately
Save and reopen StockReport, allowing an update only for the known practice source. Confirm the three item names and total 40. The Navigator’s Linked areas section can help locate the imported area and inspect its source location.
If you later choose a refresh interval, remember that it is expressed in seconds and can replace data while you work. Manual refresh is easier to audit for a small report. Keep the source workbook available, and test the link after moving either file. A displayed old table is a cached result, not evidence that the external source is reachable.