Tag: technology

Questions Related to technology

Which type of argument passes a value from a calling environment?

  1. a) VARCHER2.

  2. b) BOOLEAN.

  3. c) OUT.

  4. d) IN.


Correct Option: D
Explanation:

To answer this question, the user needs to have knowledge of different types of arguments in programming.

a) VARCHER2: This is not a type of argument. It is a data type used to store character strings in Oracle database.

b) BOOLEAN: This is not a type of argument that passes a value from a calling environment.

c) OUT: This type of argument passes a value to the calling environment. It is used when a function or procedure needs to return more than one value.

d) IN: This type of argument passes a value from the calling environment to the function or procedure. It is used when a function or procedure needs to receive values from the calling environment.

Therefore, the correct answer is:

The Answer is: D. IN.

  1. Returns error.

  2. Lists your last logins.

  3. Returns your username.

  4. Tells you where you currently are.


Correct Option: C
  1. Compares files, and shows where they differ.

  2. Tells you how many lines, words, and characters there are in a file.

  3. Removes a file

  4. Shows the first part of a file.


Correct Option: B

All users currently have the INSERT privileges on the PLAYER table. You want only your users to insert into this table using the ADD_PLAYER procedure. Which two actions must you take? (Choose two)

  1. a) GRANT SELECT ON ADD_PLAYER TO PUBLIC;

  2. b) GRANT EXECUTE ON ADD_PLAYER TO PUBLIC;

  3. c) GRANT INSERT ON PLAYER TO PUBLIC;

  4. d) GRANT EXECUTE, INSERT ON ADD_PLAYER TO PUBLIC;

  5. e) REVOKE INSERT ON PLAYER FROM PUBLIC;


Correct Option: B,E

AI Explanation

To ensure that only your users can insert into the PLAYER table using the ADD_PLAYER procedure, you need to take the following two actions:

B) GRANT EXECUTE ON ADD_PLAYER TO PUBLIC: This grants the public role the permission to execute the ADD_PLAYER procedure.

E) REVOKE INSERT ON PLAYER FROM PUBLIC: This revokes the insert privilege on the PLAYER table from the public role, ensuring that only your users can insert into the table.

Let's go through each option to understand why it is correct or incorrect:

A) GRANT SELECT ON ADD_PLAYER TO PUBLIC: This grants the public role the permission to select data from the ADD_PLAYER procedure. However, this does not restrict the insert privilege on the PLAYER table, so it is not necessary for achieving the desired outcome.

B) GRANT EXECUTE ON ADD_PLAYER TO PUBLIC: This option is correct because it grants the public role the permission to execute the ADD_PLAYER procedure. This allows all users to execute the procedure, which is necessary for inserting into the PLAYER table using the procedure.

C) GRANT INSERT ON PLAYER TO PUBLIC: This grants the public role the insert privilege on the PLAYER table. However, this does not ensure that only your users can insert into the table using the ADD_PLAYER procedure, so it is not necessary for achieving the desired outcome.

D) GRANT EXECUTE, INSERT ON ADD_PLAYER TO PUBLIC: This grants the public role the permission to execute the ADD_PLAYER procedure and the insert privilege on the ADD_PLAYER table. However, it does not restrict the insert privilege on the PLAYER table, so it is not necessary for achieving the desired outcome.

E) REVOKE INSERT ON PLAYER FROM PUBLIC: This option is correct because it revokes the insert privilege on the PLAYER table from the public role. This ensures that only your users can insert into the table using the ADD_PLAYER procedure.

Therefore, the correct answer is B) GRANT EXECUTE ON ADD_PLAYER TO PUBLIC and E) REVOKE INSERT ON PLAYER FROM PUBLIC.

  1. Lets you write data in file.

  2. Lets you change the read, write, and execute permissions on your files

  3. Converts plain text files into postscript for printing

  4. Lets you exchange one-line messages with another user


Correct Option: D

What is the output:class a { public static void main (String args[]) { int x; int y=10; if (y>0) { x = 10; } System.out.println(x); } }

  1. 10

  2. 0

  3. Garbage Value

  4. Compile time error


Correct Option: D
  1. Show disk space available on the system

  2. Show the last few lines of a file

  3. Show who are all logged into the local system

  4. Show error


Correct Option: C