asked 49.5k views
4 votes
Which of the following constructs can be used in PSM?

Select one or more:
a. FOR ... DO ...
b. WHILE .... DO ...
c. LOOP ... END LOOP;
d. DO ... WHILE ....

asked
User GWR
by
8.0k points

1 Answer

2 votes

Final answer:

PL/SQL, which could be what 'PSM' refers to, supports FOR ... DO ..., WHILE ... DO ..., and LOOP ... END LOOP constructs for iteration. DO ... WHILE ... is not valid in PL/SQL.

Step-by-step explanation:

The constructs that can be used in PL/SQL (Procedural Language/Structured Query Language), which I'm assuming you mean by 'PSM', include:

  • a. FOR ... DO ...
  • b. WHILE ... DO ...
  • c. LOOP ... END LOOP;

All of these constructs are part of PL/SQL's control structures that allow for iterative operations within the language. The FOR ... DO ... construct is used for looping a set number of times, the WHILE ... DO ... construct executes as long as a specified condition is true, and the LOOP ... END LOOP construct executes indefinitely until it is exited with the exit command. Option d. DO ... WHILE ... is not a syntactically correct construct in PL/SQL and is typically associated with other programming languages such as C or Java.

answered
User BSavaliya
by
8.0k points
Welcome to Qamnty — a place to ask, share, and grow together. Join our community and get real answers from real people.