{"id":1736,"date":"2026-04-28T04:20:33","date_gmt":"2026-04-28T04:20:33","guid":{"rendered":"https:\/\/craftcookcode.com\/?p=1736"},"modified":"2026-04-28T04:20:36","modified_gmt":"2026-04-28T04:20:36","slug":"qlik-replicate-getting-started-with-big-query","status":"publish","type":"post","link":"https:\/\/craftcookcode.com\/?p=1736","title":{"rendered":"Qlik Replicate: Getting started with Big Query"},"content":{"rendered":"\n<p>It is a new day and a new target endpoint in Qlik Replicate for us.<\/p>\n\n\n\n<p>What is different; it is a new target endpoint \u2013 Big Query; which we have not used before.<\/p>\n\n\n\n<p>Usually for our Date Lake, the steps are Source System -&gt; Qlik Replicate -&gt; JSON files -&gt; GCS -&gt; DBT -&gt; Big query.&nbsp;<\/p>\n\n\n\n<p>But this use case was different, a more tactical solution to get some tables off a legacy Data Warehouse straight into Big Query and bypassing the GCS and DBT combination.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Sharing Credentials.<\/h2>\n\n\n\n<p>In our organisation credentials are stored in their own project and are separated from other GCP resources.&nbsp; This is so that the credentials are centrally located in one project and we are not duplicating credentials across multiple projects.<\/p>\n\n\n\n<p>The Cloudies created a Service Account for us in project_x and pointed to a \u201cscratchpad\u201d dataset in project_y for Qlik Replicate to create the tables and copy across the data.&nbsp; We can then use the generated table schema to generate tables subsequent environments where Qlik doesn\u2019t have create permissions.<\/p>\n\n\n\n<p>But the problem was that the credentials were in project_x; but I could not force Qlik Replicate to write to project_y.&nbsp; Initially I thought I needed to prefix the schema with the project; like how it appears in big query:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: sql; title: ; notranslate\" title=\"\">\nSELECT * FROM `project_y.scratchpad.my_table` \n<\/pre><\/div>\n\n\n<p>This didn\u2019t work and looking at the log file with verbose turned up; I could still see it was trying to write to project_x.<\/p>\n\n\n\n<p>I asked the <a href=\"https:\/\/community.qlik.com\/t5\/Qlik-Replicate\/QR-Big-Query-Writing-to-a-different-project-than-the-credentials\/m-p\/2547818\" target=\"_blank\" rel=\"noopener\" title=\"\">Qlik forum<\/a>.<\/p>\n\n\n\n<p>While I was waiting for replies on the forum and trying a couple of suggestions; I had a look at the credential json that I downloaded from Secrets manager:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: jscript; title: ; notranslate\" title=\"\">\n{\n  &quot;type&quot;: &quot;service_account&quot;,\n  &quot;project_id&quot;: &quot;project_x&quot;,\n  &quot;private_key_id&quot;: &quot;1234567890abcdef&quot;,\n  &quot;private_key&quot;: &quot;-----BEGIN PRIVATE KEY-----\\nLongPrivateKey\\n-----END PRIVATE KEY-----\\n&quot;,\n  &quot;client_email&quot;: &quot;myaccount@project_x.iam.gserviceaccount.com&quot;,\n  &quot;client_id&quot;: &quot;123456789012345678900&quot;,\n  &quot;auth_uri&quot;: &quot;https:\/\/accounts.google.com\/o\/oauth2\/auth&quot;,\n  &quot;token_uri&quot;: &quot;https:\/\/oauth2.googleapis.com\/token&quot;,\n  &quot;auth_provider_x509_cert_url&quot;: &quot;https:\/\/www.googleapis.com\/oauth2\/v1\/certs&quot;,\n  &quot;client_x509_cert_url&quot;: &quot;https:\/\/www.googleapis.com\/robot\/v1\/metadata\/x509\/myaccount%40project_x.iam.gserviceaccount.com&quot;,\n  &quot;universe_domain&quot;: &quot;googleapis.com&quot;\n}\n<\/pre><\/div>\n\n\n<p>Curiously, I changed the project_id value from project_x to project_y.&nbsp;<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: jscript; title: ; notranslate\" title=\"\">\n{\n  &quot;type&quot;: &quot;service_account&quot;,\n  &quot;project_id&quot;: &quot;project_y&quot;,\n  &quot;private_key_id&quot;: &quot;1234567890abcdef&quot;,\n  &quot;private_key&quot;: &quot;-----BEGIN PRIVATE KEY-----\\nLongPrivateKey\\n-----END PRIVATE KEY-----\\n&quot;,\n  &quot;client_email&quot;: &quot;myaccount@project_x.iam.gserviceaccount.com&quot;,\n  &quot;client_id&quot;: &quot;123456789012345678900&quot;,\n  &quot;auth_uri&quot;: &quot;https:\/\/accounts.google.com\/o\/oauth2\/auth&quot;,\n  &quot;token_uri&quot;: &quot;https:\/\/oauth2.googleapis.com\/token&quot;,\n  &quot;auth_provider_x509_cert_url&quot;: &quot;https:\/\/www.googleapis.com\/oauth2\/v1\/certs&quot;,\n  &quot;client_x509_cert_url&quot;: &quot;https:\/\/www.googleapis.com\/robot\/v1\/metadata\/x509\/myaccount%40project_x.iam.gserviceaccount.com&quot;,\n  &quot;universe_domain&quot;: &quot;googleapis.com&quot;\n}\n<\/pre><\/div>\n\n\n<p>And it worked!<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Rounding out the settings<\/h2>\n\n\n\n<p>From there &#8211; it was pretty easy to work out the rest of the settings:<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><thead><tr><th>Big Query Section<\/th><th>Were to set<\/th><\/tr><\/thead><tbody><tr><td>Project ID<\/td><td>In the Endpoint credentials<\/td><\/tr><tr><td>Dataset<\/td><td>In the &#8220;Table Schema&#8221; for a table<\/td><\/tr><tr><td>Table Name<\/td><td>In the &#8220;Table Name&#8221; for a section<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<figure class=\"wp-block-image size-large\"><img fetchpriority=\"high\" decoding=\"async\" width=\"1024\" height=\"421\" src=\"https:\/\/craftcookcode.com\/wp-content\/uploads\/2026\/04\/code_qr_credentials_2-1024x421.png\" alt=\"\" class=\"wp-image-1740\" srcset=\"https:\/\/craftcookcode.com\/wp-content\/uploads\/2026\/04\/code_qr_credentials_2-1024x421.png 1024w, https:\/\/craftcookcode.com\/wp-content\/uploads\/2026\/04\/code_qr_credentials_2-300x123.png 300w, https:\/\/craftcookcode.com\/wp-content\/uploads\/2026\/04\/code_qr_credentials_2-768x316.png 768w, https:\/\/craftcookcode.com\/wp-content\/uploads\/2026\/04\/code_qr_credentials_2-1536x632.png 1536w, https:\/\/craftcookcode.com\/wp-content\/uploads\/2026\/04\/code_qr_credentials_2.png 2030w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>If you&#8217;re writing control tables out to Big Query; you will need to add the target dataset to the task&#8217;s properties<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"587\" src=\"https:\/\/craftcookcode.com\/wp-content\/uploads\/2026\/04\/code_qr_credentials_3-1024x587.png\" alt=\"\" class=\"wp-image-1741\" srcset=\"https:\/\/craftcookcode.com\/wp-content\/uploads\/2026\/04\/code_qr_credentials_3-1024x587.png 1024w, https:\/\/craftcookcode.com\/wp-content\/uploads\/2026\/04\/code_qr_credentials_3-300x172.png 300w, https:\/\/craftcookcode.com\/wp-content\/uploads\/2026\/04\/code_qr_credentials_3-768x440.png 768w, https:\/\/craftcookcode.com\/wp-content\/uploads\/2026\/04\/code_qr_credentials_3.png 1280w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>This can be found under the Qlik Replicate task&#8217;s json directory in the following location:<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: jscript; title: ; notranslate\" title=\"\">\ntask_json&#x5B;&quot;cmd.replication_definition&quot;]&#x5B;&quot;tasks&quot;]&#x5B;0]&#x5B;&quot;task_settings&quot;]&#x5B;&quot;target_settings&quot;]&#x5B;&quot;control_schema&quot;]\n<\/pre><\/div>\n\n\n<h2 class=\"wp-block-heading\">Conclusion and Next Steps<\/h2>\n\n\n\n<p>We did an initial run in development as a POC and to shake out any permission issue.&nbsp; So far; no issues and the destination tables were created and written to in Big Query.&nbsp; Once we are a bit more stable; I will do a couple of rough benchmarks between writing to Big Query vs to GCS with json.<\/p>\n\n\n\n<p>The Cloudies and Data Lake developers are now trying to work out what is the best way to manage the permissions by their infrastructure code in higher environments.&nbsp; In the meantime, I am modifying our QR task migration pipeline to have a variable destination table schema as the schema (which relates to dataset in Big Query) will change moving from environment to environment.&nbsp; It should be easy to do since we have python wrapper classes over the top of the Qlik Replicate json code.&nbsp; It will just be a new method to change table owners to a passed in variable.<\/p>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>It is a new day and a new target endpoint in Qlik Replicate for us. What is different; it is a new target endpoint \u2013 Big&#46;&#46;&#46;<\/p>\n","protected":false},"author":1,"featured_media":1737,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[16],"tags":[105,36],"class_list":["post-1736","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-qlik-replicate","tag-big_query","tag-qlikreplicate"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/craftcookcode.com\/index.php?rest_route=\/wp\/v2\/posts\/1736","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/craftcookcode.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/craftcookcode.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/craftcookcode.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/craftcookcode.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1736"}],"version-history":[{"count":3,"href":"https:\/\/craftcookcode.com\/index.php?rest_route=\/wp\/v2\/posts\/1736\/revisions"}],"predecessor-version":[{"id":1742,"href":"https:\/\/craftcookcode.com\/index.php?rest_route=\/wp\/v2\/posts\/1736\/revisions\/1742"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/craftcookcode.com\/index.php?rest_route=\/wp\/v2\/media\/1737"}],"wp:attachment":[{"href":"https:\/\/craftcookcode.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1736"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/craftcookcode.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1736"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/craftcookcode.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1736"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}