Cloud SQL for PostgreSQL: Qwik Start - GSP152

A passionate full-stack developer from @ePlus.DEV
Search for a command to run...

A passionate full-stack developer from @ePlus.DEV
No comments yet. Be the first to comment.
Quick and practical tips to help users optimize tasks, improve skills, and solve common problems effectively across various areas like tech, lifestyle, productivity, and more.
Một bản tin giúp Developer cập nhật nhanh AI, Cloud, Open Source và những công nghệ đáng chú ý trong ngày. 📌 Executive Summary Vercel AI Gateway thêm Grok Imagine Image 2.0 Preview, đưa image gene

Một bản tin giúp Developer cập nhật nhanh AI, Cloud, Open Source và những công nghệ đáng chú ý trong ngày. 📌 Executive Summary Cloudflare đang hợp nhất Workers AI và AI Gateway thành một control p

Một bản tin giúp Developer cập nhật nhanh AI, Cloud, Open Source và những công nghệ đáng chú ý trong ngày. 📌 Executive Summary GitHub thay đổi hành vi của Code Quality: bật Code Quality sẽ không c

Một bản tin giúp Developer cập nhật nhanh AI, Cloud, Open Source và những công nghệ đáng chú ý trong ngày. 📌 Executive Summary OpenAI thay đổi thời điểm tính phí seat mới của ChatGPT Business từ n

Overview Dataplex is an intelligent data fabric that enables organizations to centrally discover, manage, monitor, and govern their data across data lakes, data warehouses, and data marts to power ana

In this lab you'll learn how to create and connect to a Google Cloud SQL PostgreSQL instance and perform basic SQL operations using the Cloud Console and the psql client.
Click on the menu icon in the top left of the screen to see the Navigation menu ().
In the left menu of the Console, click on SQL.
Click Create Instance.
Click Choose PostgreSQL.
Create your instance with the following settings:
Enter myinstance for Instance ID.
Enter a password for the postgres user. Save or remember this password, you'll need it in the next section.
For Choose a Cloud SQL edition, select Enterprise.
For Region select europe-west1.
Leave the default values for the other fields.
You are returned to the instances list. Your new instance is greyed out while it initializes and starts.
After a few minutes your instance is created and you can continue to the next section. If it seems to be taking a long time refresh your browser.
Test completed task
Click Check my progress to verify your performed task. If you have completed the task successfully you will granted with an assessment score.
Create a Cloud SQL instance
Check my progress
Below are multiple choice questions to reinforce your understanding of this lab's concepts. Answer them to the best of your abilities.
What PostgreSQL Database version used in lab to create Cloud SQL instance?15.45.75.61.0
Submit
In the Cloud Console, click Cloud Shell () in the upper right corner.
Then click Continue if prompted.
At the Cloud Shell prompt, connect to your Cloud SQL instance by running:
gcloud sql connect myinstance --user=postgres
Note: The cursor will not move. Press Enter when you're done typing.
You should now see the psql prompt.
CREATE TABLE guestbook (guestName VARCHAR(255), content VARCHAR(255), entryID SERIAL PRIMARY KEY);
INSERT INTO guestbook (guestName, content) values ('first guest', 'I got here!');
INSERT INTO guestbook (guestName, content) values ('second guest', 'Me too!');
SELECT * FROM guestbook;
You should now see:
guestname | content | entryid
--------------+-------------+---------
first guest | I got here! | 1
second guest | Me too! | 2
(2 rows)
postgres=>
You have created a Google Cloud SQL PostgreSQL instance and connected to it.
Below are multiple choice questions to reinforce your understanding of this lab's concepts. Answer them to the best of your abilities.
What is the name of default database in Postgres Cloud SQL instance?
information_schema
guestbook
performance_schema
postgres
curl -LO raw.githubusercontent.com/ePlus-DEV/storage/refs/heads/main/labs/GSP152/lab.sh
source lab.sh
export REGION=

curl -LO raw.githubusercontent.com/quiccklabs/Labs_solutions/master/Cloud%20SQL%20for%20PostgreSQL%20Qwik%20Start/quicklabgsp152.sh
sudo chmod +x quicklabgsp152.sh
./quicklabgsp152.sh