News Ticker

Menu

UpWork (oDesk) & Elance PostgreSQL RDBMS Test Question & Answers

UpWork (oDesk) & Elance PostgreSQL RDBMS Test Question & Answers are really very important to pass UpWork & Elance test. You will get top score at this skill test exam. If you found any problem or wrong answer please inform me via contact or comments. We will try to solve it in short. This test is extremely valuable to acquire knowledge of PostgreSQL RDBMS. Lets Start test.


Ques : Which authentication methods are supported by PostgreSQL?
Ans  :  Trust
        PAM
        LDAP
        Radius
        Password

Ques : Which index types are supported by PostgreSQL?
Ans  :  B-tree
        GiST
        Hash
        GIN

Ques : Out of the following backup approaches, which ones are applicable to PostgreSQL?
Ans  : SQL dump
       File system level backup
   Continuous archiving

Ques : In the following operation, which ones can trigger a trigger?
Ans  : insert
       update
   delete

Ques : Which index types support multicolumn indexes?
Ans  : B-tree
       GiST
   GIN

Ques : What kind of triggers are offered by PostgreSQL?
Ans  : Per-row triggers
      Per-statement triggers

Ques : Which of the following statements will cast the integer value 1 to type text?
Ans  :  SELECT CAST(1, text) as cast_integer;
        SELECT 1::text AS cast_integer;
 
Ques : Are the contents of the pg_autovacuum system catalog saved when pg_dumpall is used to backup the database?
Ans  : No

Ques : Can deferrable constraints be deferred by a trigger?
Ans  : Yes

Ques : After a PostgreSQL installation, how will you create the database cluster?
Ans  :  With initd

Ques : Consider the following query:

Create table foo (bar varchar);

What will be the size limit of the bar?
Ans  :  No limit (It will be equivalent to the text)

Ques : What is the difference between to_tsvector() and ::tsvector ?
Ans  :  to_tsvector () can be used in select statements, while ::tsvector cannot

Ques : While creating a trigger, the function it will call may be created after it and attached to it.
Ans  : True

Ques :  What is the command used to import a backup made with pg_dumpall > file.dmp?
Ans  :  psql -f file.dmp

Ques : An ISO-8601 time may be entered into a table using the numeric format 012411 instead of 01:24:11.
Ans  : True

Ques : Consider the following empty table:

CREATE TABLE example (
    a integer,
    b integer,
    c integer,
    UNIQUE (a, c)
);

Which of the following inserts will cause an error?
Ans  : insert into example (a, b, c) values (1, 2, 3), (1, 4, 3);

Ques : What is the effect of turning fsync off in postgresql.conf?
Ans  : File synchronization will be deactivated

Ques : What is the ~ operator?
Ans  : POSIX regular expression match operator

Ques : What is the default ordering when ORDER BY is not specified?
Ans  : The ordering is unknown if not specified

Ques : Which one of the following text search functions does not exist?
Ans  :  plainto_tsvecto

Ques : Which PostgreSQL version added the enum datatype?
Ans  : 8.0

Ques :  While creating a table with a field of the serial type, a sequence will be created.
Ans  :  True

Ques : What can be stored in a column of type decimal(4,3)?
Ans  : 4 numeric values with up to 3 digits to the right of the decimal point.

Ques : What interfaces are available in the base distribution of PostgreSQL?
Ans  : C

Ques : A table can have only one primary key column.
Ans  : True

Ques : What command will correctly restore a backup made with the following command?
pg_dump -Fc dbname > filename
Ans  : psql -f filename dbname

Ques :   How can you configure PostgreSQL autovacuum?
Ans  : By editing postgresql.conf

Ques :  What library is used by PostgreSQL for encryption?
Ans  : None of the above

Ques : On a UNIX system, what is the best way to prevent all non-local connections to the postmaster?
Ans  :  None of the above

Ques : How will you change the TCP port which PostgreSQL will listen to?
Ans  : By changing "port" in postgresql.conf

Ques : Which of the following queries will create a table with two fields, "id" and "name" with "id" as an auto incrementing primary key?
Ans  :  create table foo (id serial primary key, name varchar(255));

Ques : How will you list the available functions from psql?
Ans  :  \df

Ques : What is the well known port number for the postgresql database service?
Ans  : 5432

Ques : What is true regarding file system backup?
Ans  : All of the above

Ques : How do you alter a column to forbid null values?
Ans  : None of the above

Ques : What is the storage size of an integer on a 64bit system?
Ans  : 4bytes

Ques : Which function should be used to highlight the results?
Ans  :  ts_highlight

Ques : When using LIKE to compare strings, what is the wildcard operator (operator which matches zero or more characters)?
Ans  : *

Ques : For proper results, which of the following should contain a tsvector?
Ans  : Lexemes

Ques : Which of the following statements will produce an error?
Ans  :  SELECT now()::int;

Ques : To backup a database, the postmaster daemon must be halted.
Ans  : True

Ques : The following statement will retrieve the second element of the array column products in table store_products.

SELECT products[1] FROM store_products;
Ans  : True

Ques : SELECT 'infinity'::timestamp;

Will this statement produce an error?
Ans  : Yes

Ques :  What is the difference between tokens and lexemes?
Ans  :  A lexeme is a string while a token is an intege

Ques : Which kind of index can be declared unique?
Ans  : Hash

Ques :  SELECT rtrim('foobar', 'abr');

The result of this statement is foo.
Ans  : True

Ques : SELECT !!3;

What output will this statement give?
Answers:
Ans  : 6

Ques : How do you create a table with a field of the int array type?
Ans  : create table foo (bar integer[]);

Ques : create table foo (bar integer[]);
Ans  : None of the above

Ques : Which of the following statements will create a table with a multidimensional array as second column?
Ans  : CREATE TABLE favorite_books (customer_id integer, themes_and_titles text[][]);

Ques : If max_connections is 10 and 10 connections are currently active, how can you be sure the superuser will be available to connect?
Ans  :  Set superuser_reserved_connections in postgresql.conf

Ques : How will you rank text search results?
Ans  : With the ORDER BY operator

Ques : Which of the following statements will create a table special_products which is a child of the table store_products?
Ans  : CREATE TABLE special_products (quality int) INHERITS store_products;

Ques : Which of the following statements will create a table?
Ans  : SELECT * INTO products_backup FROM special_products;

Ques : Which of the following statements will retrieve the number of values stored in an array column?
Ans  : SELECT array_dims(products) FROM store_products;

Ques : Does PostgreSQL support SSL?
Ans  : Yes

Ques : Given a table special_products that inherits from a table store_products, which of the following statements will modify store_products only without affecting its child table?
Ans  : UPDATE ONLY store_products SET name = 'Wine' WHERE id = 2;

Ques : How do you select a single random row from a table?
Ans  : SELECT * FROM tab ORDER BY random() LIMIT 1;

Ques : PostgreSQL triggers can be written in C directly.
Ans  : True

Thanks for watching this test Question & Answers. Please don't forget to leave a comment about this post. You can also find some more effective test question & answers, information, techniques, technology news, tutorials, online earning information, recent news, results, job news, job exam results, admission details & another related services on the following sites below. Happy Working!
News For Todays ARSBD oEtab ARSBD-JOBS DesignerTab

Share This:

oEtab

We're UpWok-Elance Test Answers Team. We provide latest online earning test question and answers. Here is also available top earning tips and tutorials. Always We're updating all latest question and answers. If you need any help please don't hesitate to contact us.

No Comment to " UpWork (oDesk) & Elance PostgreSQL RDBMS Test Question & Answers "

We recommend you to subscribe us to get update from your email. If you want to ad a comment about our posts on this website just Sign Up here.

  • To add an Emoticons Show Icons
  • To add code Use [pre]code here[/pre]
  • To add an Image Use [img]IMAGE-URL-HERE[/img]
  • To add Youtube video just paste a video link like http://www.youtube.com/watch?v=0x_gnfpL3RM