InterviewSolution
| 1. |
Does VARRAY exist in PL/SQL? |
|
Answer» Sequence of characters are called STRINGS. Just like any other language, a string can be letters, numbers, special characters, etc. The following are the three types of strings in PL/SQL:
In fixed-length strings, the length is to be specified while DECLARING a string. The string is right-padded with spaces to the length so specified.
A maximum length up to 32,767 for the string is specified and no padding TAKES place.
CLOBs are variable-length strings that can be up to 128 terabytes. Let us see how we can declare a String variable. We have a lot of string datatypes, such as CHAR, NCHAR, VARCHAR2, NVARCHAR2, CLOB, and NCLOB in PL/SQL. The declaration: DECLARE cars varchar2(25) := 'Bentley;Let us see an example where we have two variables: DECLARE CAR varchar2(15) := 'Bentley'; device varchar2(11) := 'Laptop'; BEGIN dbms_output.put_line(UPPER(car)); dbms_output.put_line(LOWER(car)); dbms_output.put_line(device); dbms_output.put_line(UPPER(device)); END; /The output: BENTLEY bentley Laptop LAPTOP |
|