{"id":9047,"date":"2026-09-16T11:09:16","date_gmt":"2026-09-16T11:09:16","guid":{"rendered":"https:\/\/prwatech.in\/blog\/?p=9047"},"modified":"2026-09-17T05:47:41","modified_gmt":"2026-09-17T05:47:41","slug":"accessing-cloud-sql-from-bigquery","status":"publish","type":"post","link":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/","title":{"rendered":"Accessing Cloud SQL from BigQuery"},"content":{"rendered":"\r\n<h1>Querying Cloud SQL Data in BigQuery<\/h1>\r\n<p class=\"wp-block-paragraph\">BigQuery can query data sitting in a Cloud SQL instance directly, without first copying it in, using a feature called a <strong><b>federated query<\/b><\/strong>. You set up a connection once, then reference it inside a query using the EXTERNAL_QUERY function, and BigQuery sends your query to Cloud SQL, gets the result back, and converts it into BigQuery&#8217;s own data types.<\/p>\r\n<h2>Step by Step Process of Querying Cloud SQL Data in BigQuery<\/h2>\r\n<h3>Step One: Enable the BigQuery Connection API<\/h3>\r\n<p>In the console, open the menu, then go to APIs and Services, then Library.<\/p>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Open Menu &gt; API &amp; Services &gt; Library<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"457\" height=\"333\" class=\"wp-image-9048\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-399.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-399.png 457w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-399-300x219.png 300w\" sizes=\"auto, (max-width: 457px) 100vw, 457px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Search for the BigQuery Connection API and open it.<\/p>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Open It.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-9049\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-400.png\" alt=\"\" width=\"696\" height=\"174\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-400.png 628w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-400-300x75.png 300w\" sizes=\"auto, (max-width: 696px) 100vw, 696px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Click on Enable to enable API<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"628\" height=\"245\" class=\"wp-image-9050\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-401.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-401.png 628w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-401-300x117.png 300w\" sizes=\"auto, (max-width: 628px) 100vw, 628px\" \/><\/figure>\r\n\r\n\r\n\r\n<h3>Step Two: Open Your Cloud SQL Instance<\/h3>\r\n<p class=\"wp-block-paragraph\">Open the menu, then go to SQL.<\/p>\r\n<p>menu &gt; SQL<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"277\" height=\"361\" class=\"wp-image-9051\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-402.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-402.png 277w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-402-230x300.png 230w\" sizes=\"auto, (max-width: 277px) 100vw, 277px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Open your Cloud SQL instance.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"628\" height=\"155\" class=\"wp-image-9052\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-403.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-403.png 628w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-403-300x74.png 300w\" sizes=\"auto, (max-width: 628px) 100vw, 628px\" \/><\/figure>\r\n\r\n\r\n\r\n<h3>Step Three: Choose Public or Private IP<\/h3>\r\n<p class=\"wp-block-paragraph\">Open the Connections tab.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"263\" height=\"258\" class=\"wp-image-9053\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-404.png\" alt=\"\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">For a quick test, confirm Public IP is enabled here. For anything beyond a scratch project, consider configuring private IP connectivity instead, and selecting the enable private path option on the BigQuery side when you create the connection in the next step. Private connectivity keeps traffic between BigQuery and Cloud SQL off the public internet entirely, which current <a href=\"https:\/\/prwatech.in\/gcp-training-institutes-in-pune\/\">Google Cloud<\/a> guidance treats as the safer default.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"544\" height=\"335\" class=\"wp-image-9054\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-405.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-405.png 544w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-405-300x185.png 300w\" sizes=\"auto, (max-width: 544px) 100vw, 544px\" \/><\/figure>\r\n<h3>Step Four: Start Creating the Connection in BigQuery<\/h3>\r\n<p>Open the menu, then go to BigQuery.<\/p>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Open Menu &gt; BigQuery<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"292\" height=\"274\" class=\"wp-image-9055\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-406.png\" alt=\"\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Click on Add Data &gt; External Data Source<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"300\" height=\"305\" class=\"wp-image-9056\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-407.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-407.png 300w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-407-295x300.png 295w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Choose your connection type, matching the database engine your Cloud SQL instance runs, MySQL or PostgreSQL. Give the connection an ID and choose a data location. Pick the same location as your Cloud SQL instance, since a federated query can only run against a resource in the same region as the connection.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"479\" height=\"212\" class=\"wp-image-9057\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-408.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-408.png 479w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-408-300x133.png 300w\" sizes=\"auto, (max-width: 479px) 100vw, 479px\" \/><\/figure>\r\n<h3>Step Five: Copy the Cloud SQL Connection Name<\/h3>\r\n<p>In a new tab, open the menu, then SQL, then your instance&#8217;s Overview page, and copy its connection name.<\/p>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">In new tab, Open Menu &gt; SQL Instance &gt; Overview Copy the connection name<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-9058\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-409.png\" alt=\"\" width=\"763\" height=\"274\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-409.png 628w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-409-300x108.png 300w\" sizes=\"auto, (max-width: 763px) 100vw, 763px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Click on users. If your user account is there, you can skip this step. Else add the user accoount.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"628\" height=\"221\" class=\"wp-image-9059\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-410.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-410.png 628w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-410-300x106.png 300w\" sizes=\"auto, (max-width: 628px) 100vw, 628px\" \/><\/figure>\r\n\r\n\r\n\r\n<h3>Step Six: Confirm or Add a Database User<\/h3>\r\n<p class=\"wp-block-paragraph\">Click Users. If the account you want to connect with is already listed, you can skip ahead. Otherwise, add it.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"573\" height=\"383\" class=\"wp-image-9060\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-411.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-411.png 573w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-411-300x201.png 300w\" sizes=\"auto, (max-width: 573px) 100vw, 573px\" \/><\/figure>\r\n\r\n\r\n\r\n<h3>Step Seven: Finish Creating the Connection<\/h3>\r\n<p class=\"wp-block-paragraph\">Back in the BigQuery tab, paste the Cloud SQL instance connection name, along with the database name, username, and password for the account you just confirmed or created. Click Create Connection.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"497\" height=\"330\" class=\"wp-image-9061\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-412.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-412.png 497w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-412-300x199.png 300w\" sizes=\"auto, (max-width: 497px) 100vw, 497px\" \/><\/figure>\r\n\r\n\r\n\r\n<h3>Step Eight: Share the Connection, if Needed<\/h3>\r\n<p class=\"wp-block-paragraph\">If other people need to view, edit, or otherwise use this connection, click Share Connection.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-9062\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-413.png\" alt=\"\" width=\"732\" height=\"260\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-413.png 628w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-413-300x107.png 300w\" sizes=\"auto, (max-width: 732px) 100vw, 732px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">The connection will be created.<\/p>\r\n<p>Enter their email address, choose a role, click Add, then Done.<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"517\" height=\"567\" class=\"wp-image-9063\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-414.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-414.png 517w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-414-274x300.png 274w\" sizes=\"auto, (max-width: 517px) 100vw, 517px\" \/><\/figure>\r\n\r\n\r\n\r\n<h3>Step Nine: Run a Federated Query<\/h3>\r\n<p class=\"wp-block-paragraph\">Click Query Connection. This adds a starter query into the query editor:<\/p>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">SELECT * FROM EXTERNAL_QUERY(\u201c&lt;project-ID&gt;.&lt;Location&gt;.&lt;connection-ID&gt;\u201d,\u201d&lt;SQL QUERY&gt;\u201d);<\/p>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-9064\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-415.png\" alt=\"\" width=\"685\" height=\"412\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-415.png 628w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-415-300x181.png 300w\" sizes=\"auto, (max-width: 685px) 100vw, 685px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">Change only the SQL query text inside the quotes, written in your Cloud SQL database&#8217;s own SQL dialect. Leave the EXTERNAL_QUERY function call and the project, location, and connection ID section exactly as generated. Click Run, and it executes the same as any other BigQuery query.<\/p>\r\n\r\n\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"578\" height=\"366\" class=\"wp-image-9065\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-416.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-416.png 578w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-416-300x190.png 300w\" sizes=\"auto, (max-width: 578px) 100vw, 578px\" \/><\/figure>\r\n\r\n\r\n\r\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"581\" height=\"516\" class=\"wp-image-9066\" src=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-417.png\" alt=\"\" srcset=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-417.png 581w, https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-417-300x266.png 300w\" sizes=\"auto, (max-width: 581px) 100vw, 581px\" \/><\/figure>\r\n\r\n\r\n\r\n<p class=\"wp-block-paragraph\">&nbsp;<\/p>\r\n<h2>An Important Limitation: Federated Queries Are Read Only<\/h2>\r\n<p>A federated query can only read data out of Cloud SQL. You cannot use EXTERNAL_QUERY to insert, update, or delete rows back in the source database. If your workflow needs to write data somewhere, that write has to happen through a normal connection to Cloud SQL directly, not through this BigQuery connection.<\/p>\r\n<h2>Common Mistakes to Avoid<\/h2>\r\n<ul>\r\n<li>Placing the BigQuery connection and the Cloud SQL instance in different regions. A federated query can only reach a resource in the same region as the connection, so a mismatch here will fail rather than just run slowly.<\/li>\r\n<li>Leaving public IP open without restricting authorized networks. If you do use public IP, restrict which IP ranges can connect to the instance at all, rather than leaving it open to any address.<\/li>\r\n<li>Editing the wrong part of the generated query. The project, location, and connection ID section inside EXTERNAL_QUERY is generated for you and should stay untouched. Only the SQL query string inside it needs to change.<\/li>\r\n<\/ul>\r\n<p>Expecting to write data back through this connection. Federated queries are read only, so plan any writes back to Cloud SQL through a separate, direct connection.<\/p>\r\n<p>That covers connecting BigQuery to Cloud SQL and running a federated query against it. To go further, explore <a href=\"https:\/\/prwatech.in\/gcp-training-institutes-in-bangalore\/\"><strong><b>Prwatech&#8217;s Google Cloud training<\/b><\/strong>\u00a0program<\/a>, which includes placement assistance.<\/p>\r\n","protected":false},"excerpt":{"rendered":"<p>Querying Cloud SQL Data in BigQuery BigQuery can query data sitting in a Cloud SQL instance directly, without first copying it in, using a feature called a federated query. You set up a connection once, then reference it inside a query using the EXTERNAL_QUERY function, and BigQuery sends your query to Cloud SQL, gets the [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1632,1],"tags":[732,1416,1419,1417,605,699,700,617,683,684,685,611,1400,695,692,733],"class_list":["post-9047","post","type-post","status-publish","format-standard","hentry","category-bigquery","category-google-cloud-platform","tag-bigquery-sql","tag-cloud-sql-gcp","tag-cloud-sql-mysql","tag-cloud-sql-postgres","tag-gcp","tag-gcp-certification","tag-gcp-cloud-console","tag-google-cloud","tag-google-cloud-certification","tag-google-cloud-console","tag-google-cloud-courses","tag-google-cloud-platform","tag-google-cloud-platform-tutorial","tag-google-cloud-sql","tag-google-cloud-training","tag-sql-in-bigquery"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v25.7 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Querying Cloud SQL Data in BigQuery With EXTERNAL_QUERY<\/title>\n<meta name=\"description\" content=\"Query Cloud SQL data directly from BigQuery using a federated connection, with the current private IP option and a key read only limit.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Querying Cloud SQL Data in BigQuery With EXTERNAL_QUERY\" \/>\n<meta property=\"og:description\" content=\"Query Cloud SQL data directly from BigQuery using a federated connection, with the current private IP option and a key read only limit.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/\" \/>\n<meta property=\"og:site_name\" content=\"Prwatech\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/prwatech.in\/\" \/>\n<meta property=\"article:published_time\" content=\"2026-09-16T11:09:16+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2026-09-17T05:47:41+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-399.png\" \/>\n\t<meta property=\"og:image:width\" content=\"457\" \/>\n\t<meta property=\"og:image:height\" content=\"333\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Prwatech\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@Eduprwatech\" \/>\n<meta name=\"twitter:site\" content=\"@Eduprwatech\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Prwatech\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"8 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/\",\"url\":\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/\",\"name\":\"Querying Cloud SQL Data in BigQuery With EXTERNAL_QUERY\",\"isPartOf\":{\"@id\":\"https:\/\/prwatech.in\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-399.png\",\"datePublished\":\"2026-09-16T11:09:16+00:00\",\"dateModified\":\"2026-09-17T05:47:41+00:00\",\"author\":{\"@id\":\"https:\/\/prwatech.in\/blog\/#\/schema\/person\/db90baff7744090b2288bbc98fea87f3\"},\"description\":\"Query Cloud SQL data directly from BigQuery using a federated connection, with the current private IP option and a key read only limit.\",\"breadcrumb\":{\"@id\":\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/#primaryimage\",\"url\":\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-399.png\",\"contentUrl\":\"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-399.png\",\"width\":457,\"height\":333},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/prwatech.in\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Accessing Cloud SQL from BigQuery\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/prwatech.in\/blog\/#website\",\"url\":\"https:\/\/prwatech.in\/blog\/\",\"name\":\"Prwatech\",\"description\":\"Share Ideas, Start Something Good.\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/prwatech.in\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/prwatech.in\/blog\/#\/schema\/person\/db90baff7744090b2288bbc98fea87f3\",\"name\":\"Prwatech\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/prwatech.in\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/c00bafc1b04045f31eda917de39891456c44fa47c092b9bb6be0f860a3a30a2f?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/c00bafc1b04045f31eda917de39891456c44fa47c092b9bb6be0f860a3a30a2f?s=96&d=mm&r=g\",\"caption\":\"Prwatech\"},\"url\":\"https:\/\/prwatech.in\/blog\/author\/prwatech123\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Querying Cloud SQL Data in BigQuery With EXTERNAL_QUERY","description":"Query Cloud SQL data directly from BigQuery using a federated connection, with the current private IP option and a key read only limit.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/","og_locale":"en_US","og_type":"article","og_title":"Querying Cloud SQL Data in BigQuery With EXTERNAL_QUERY","og_description":"Query Cloud SQL data directly from BigQuery using a federated connection, with the current private IP option and a key read only limit.","og_url":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/","og_site_name":"Prwatech","article_publisher":"https:\/\/www.facebook.com\/prwatech.in\/","article_published_time":"2026-09-16T11:09:16+00:00","article_modified_time":"2026-09-17T05:47:41+00:00","og_image":[{"width":457,"height":333,"url":"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-399.png","type":"image\/png"}],"author":"Prwatech","twitter_card":"summary_large_image","twitter_creator":"@Eduprwatech","twitter_site":"@Eduprwatech","twitter_misc":{"Written by":"Prwatech","Est. reading time":"8 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/","url":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/","name":"Querying Cloud SQL Data in BigQuery With EXTERNAL_QUERY","isPartOf":{"@id":"https:\/\/prwatech.in\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/#primaryimage"},"image":{"@id":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/#primaryimage"},"thumbnailUrl":"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-399.png","datePublished":"2026-09-16T11:09:16+00:00","dateModified":"2026-09-17T05:47:41+00:00","author":{"@id":"https:\/\/prwatech.in\/blog\/#\/schema\/person\/db90baff7744090b2288bbc98fea87f3"},"description":"Query Cloud SQL data directly from BigQuery using a federated connection, with the current private IP option and a key read only limit.","breadcrumb":{"@id":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/#primaryimage","url":"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-399.png","contentUrl":"https:\/\/prwatech.in\/blog\/wp-content\/uploads\/2021\/05\/image-399.png","width":457,"height":333},{"@type":"BreadcrumbList","@id":"https:\/\/prwatech.in\/blog\/google-cloud-platform\/bigquery\/accessing-cloud-sql-from-bigquery\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/prwatech.in\/blog\/"},{"@type":"ListItem","position":2,"name":"Accessing Cloud SQL from BigQuery"}]},{"@type":"WebSite","@id":"https:\/\/prwatech.in\/blog\/#website","url":"https:\/\/prwatech.in\/blog\/","name":"Prwatech","description":"Share Ideas, Start Something Good.","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/prwatech.in\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/prwatech.in\/blog\/#\/schema\/person\/db90baff7744090b2288bbc98fea87f3","name":"Prwatech","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/prwatech.in\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/c00bafc1b04045f31eda917de39891456c44fa47c092b9bb6be0f860a3a30a2f?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/c00bafc1b04045f31eda917de39891456c44fa47c092b9bb6be0f860a3a30a2f?s=96&d=mm&r=g","caption":"Prwatech"},"url":"https:\/\/prwatech.in\/blog\/author\/prwatech123\/"}]}},"_links":{"self":[{"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/posts\/9047","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/comments?post=9047"}],"version-history":[{"count":6,"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/posts\/9047\/revisions"}],"predecessor-version":[{"id":11775,"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/posts\/9047\/revisions\/11775"}],"wp:attachment":[{"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/media?parent=9047"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/categories?post=9047"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/prwatech.in\/blog\/wp-json\/wp\/v2\/tags?post=9047"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}