04.Importing Data from Other Sheets
Many times you may need to reference data from one Google Sheet in another.
You can do this easily using the Importrange function.
Sample Usage
IMPORTRANGE("abcd123abcd123", "sheet1!A1:C10")
IMPORTRANGE(A2,B2)
Syntax
IMPORTRANGE(spreadsheet_key, range_string)
spreadsheet_key - The long sequence of characters in the "key=" attribute of the URL. In the new Google Sheets, use the entire URL.
The value for spreadsheet_key must either be enclosed in quotation marks or be a reference to a cell containing the appropriate text.
range_string - A string, of the format "[sheet_name!]range" (e.g. "Sheet1!A2:B6" or "A2:B6") specifying the range to import.
The sheet_name component of range_string is optional; by default IMPORTRANGE will import from the given range of the first sheet.
The value for range_string must either be enclosed in quotation marks or be a reference to a cell containing the appropriate text.
Notes
A maximum of 50 IMPORTRANGE calls are supported on a single spreadsheet. This limit is removed in the new version of Google Sheets.
In the new version of Google Sheets, spreadsheets must be explicitly granted permission to pull data from other spreadsheets using IMPORTRANGE. The first time the destination sheet pulls data from a new source sheet, the user will be prompted to grant permission. Once access is granted, any editor on the destination spreadsheet can useIMPORTRANGE to pull from any part of the source spreadsheet. The access remains in effect until the user who granted access is removed from the source.
See Also
IMPORTXML: Imports data from any of various structured data types including XML, HTML, CSV, TSV, and RSS and ATOM XML feeds.
IMPORTHTML: Imports data from a table or list within an HTML page.
IMPORTFEED: Imports a RSS or ATOM feed.
IMPORTDATA: Imports data at a given url in .csv (comma-separated value) or .tsv (tab-separated value) format.
Examples
Defines the monthly-expense spreadsheet data.
Imports the specified range data from the monthly-expense spreadsheet.