# Query ## Definition ### [[Nexus - Google Analytics Certificate Course|Google Analytics Certificate]] >[! Definition] >A request for data or information from a database written in a [[Query language|query language]] ### Context: [[Nexus - Google Analytics Certificate Course#4.4 Google Analytics - 4 Process Module 4 - Verify and report on cleaning results|Google Analytics Certificate]] #### Sub-context: [[Function#Spreadsheet functions]] >[! definition] >Enables Pseudo SQL statements to import data. ## Examples ### Basic structure of a SQL query ```sql SELECT * -- selects all columns in what ever table specified in FROM FROM db_movies.movies -- this is the table name db_movies WHERE genre1 = "Action" ``` This is a basic query showing SQL keywords and Syntax. ```excel =QUERRY(A2:C10000, "SELECT *") ``` the above example would select everything in the selected range. #### Google Sheets syntax ```spreadsheet =QUERRY(data, query, [headers]) 'see docs in resources ``` ### Google Sheets QUERY function ## Related [[SQL]] [[Query language]] ## Resources [=QUERRY() documentation](https://support.google.com/docs/answer/3093343?hl=en)