190+ PostgreSQL MCQ With Online Practice Test

PostgreSQL, often referred to as Postgres, is a powerful open-source relational database management system (RDBMS) known for its scalability, robustness, and extensibility. It offers advanced features like ACID compliance, support for complex data types, and support for both SQL and NoSQL data. PostgreSQL is highly regarded for its performance, security, and reliability, making it a popular choice for applications ranging from small startups to large enterprises. Its active developer community continuously enhances and maintains the software. PostgreSQL is an excellent choice for data storage, analysis, and management in various domains, including web applications, data warehousing, and geospatial applications.

Practice Test

91. What is the default authentication method for PostgreSQL?

Answer: md5

92. Which PostgreSQL authentication method allows access without a password but is restricted to local connections on Unix-like systems?

Answer: peer

93. What is the purpose of the "pg_hba.conf" file in PostgreSQL?

Answer: To define access control rules for client connections

94. What does the "trust" authentication method in PostgreSQL do?

Answer: Allows access without requiring a password

95. In PostgreSQL, what is the purpose of the "scram-sha-256" authentication method?

Answer: To provide a secure and password-based authentication method

96. What is the primary role of the "role" concept in PostgreSQL's role-based access control system?

Answer: To define user accounts and their privileges

97. What is a "superuser" in PostgreSQL, and what privileges does it have?

Answer: A user with all privileges, including the ability to perform administrative tasks

98. What is the purpose of PostgreSQL's "GRANT" and "REVOKE" statements in the context of security?

Answer: To assign or remove privileges on database objects to/from roles

99. What is SSL/TLS encryption used for in PostgreSQL security?

Answer: To encrypt data transmission between the client and server

100. What is the "pgcrypto" extension in PostgreSQL used for?

Answer: To provide cryptographic functions for data encryption and decryption
Topic Tags