Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- psql-client:/# psql \
- --host=postgresql-rw \
- --port=5432 \
- --username=app \
- --password \
- app
- Password:
- psql (16.3, server 16.2 (Debian 16.2-1.pgdg110+2))
- SSL connection (protocol: TLSv1.3, cipher: TLS_AES_256_GCM_SHA384, compression: off)
- Type "help" for help.
- app=> CREATE TABLE users (
- app(> id SERIAL PRIMARY KEY,
- app(> username VARCHAR(50),
- app(> age INTEGER
- app(> );
- CREATE TABLE
- app=> INSERT INTO users (username, age) VALUES ('Alice', 25);
- ob', 30);
- INSERT INTO users (username, age) VALUESINSERT 0 1
- app=> INSERT INTO users (username, age) VALUES ('Bob', 30);
- ('Charlie', 28);
- INSERT INTO users (username, ageINSERT 0 1
- app=> INSERT INTO users (username, age) VALUES ('Charlie', 28);
- ) VALUES ('David', 35);
- INSERT INTO users (usernamINSERT 0 1
- app=> INSERT INTO users (username, age) VALUES ('David', 35);
- e, age) VALUES ('Eva', 22);
- INSERT INTO users (username, age) VALUES ('Frank', 40);
- INSERT INTO userINSERT 0 1
- app=> INSERT INTO users (username, age) VALUES ('Eva', 22);
- s (username, age) VALUES ('Grace', 33);
- INSERT INTINSERT 0 1
- app=> INSERT INTO users (username, age) VALUES ('Frank', 40);
- O users (username, age) VALUES ('Hannah', 29);
- INSINSERT 0 1
- app=> INSERT INTO users (username, age) VALUES ('Grace', 33);
- ERT INTO users (username, age) VALUES ('Iris', 27);
- INSERT INTO users (username, age) VALUES ('Jack'INSERT 0 1
- app=> INSERT INTO users (username, age) VALUES ('Hannah', 29);
- , 32);
- INSERT INTO users (username, age) VALUES ('INSERT 0 1
- app=> INSERT INTO users (username, age) VALUES ('Iris', 27);
- Kelly', 26);
- INSERT INTO users (username, age) VALUES ('Liam', 31);
- INSERT INTO users (username, ageINSERT 0 1
- app=> INSERT INTO users (username, age) VALUES ('Jack', 32);
- ) VALUES ('Mia', 24);
- INSERT INTO users (username,INSERT 0 1
- app=> INSERT INTO users (username, age) VALUES ('Kelly', 26);
- age) VALUES ('Noah', 37);INSERT 0 1
- app=> INSERT INTO users (username, age) VALUES ('Liam', 31);
- INSERT 0 1
- app=> INSERT INTO users (username, age) VALUES ('Mia', 24);
- INSERT 0 1
- app=> INSERT INTO users (username, age) VALUES ('Noah', 37);
- INSERT 0 1
- app=>
- app=>
- app=> select * from users;
- id | username | age
- ----+----------+-----
- 1 | Alice | 25
- 2 | Bob | 30
- 3 | Charlie | 28
- 4 | David | 35
- 5 | Eva | 22
- 6 | Frank | 40
- 7 | Grace | 33
- 8 | Hannah | 29
- 9 | Iris | 27
- 10 | Jack | 32
- 11 | Kelly | 26
- 12 | Liam | 31
- 13 | Mia | 24
- 14 | Noah | 37
- (14 rows)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement