0% found this document useful (0 votes)
34 views

PLSQL 2 2 Practice

The document discusses lexical units in PL/SQL including identifiers, literals, reserved words, and delimiters. It provides examples of valid and invalid identifiers and asks the reader to identify the lexical unit for different PL/SQL elements. The document is intended to teach database programming fundamentals.

Uploaded by

AFloppyBoy
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views

PLSQL 2 2 Practice

The document discusses lexical units in PL/SQL including identifiers, literals, reserved words, and delimiters. It provides examples of valid and invalid identifiers and asks the reader to identify the lexical unit for different PL/SQL elements. The document is intended to teach database programming fundamentals.

Uploaded by

AFloppyBoy
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

academy.oracle.

com

Database Programming with PL/SQL 2-


2: Recognizing PL/SQL Lexical Units
Practice Activities
Vocabulary
Identify the vocabulary word for each definition below:

An explicit numeric, character string, date, or Boolean value that is not


represented by an identifier.

Symbols that have special meaning to an Oracle database.

Words that have special meaning to an Oracle database and cannot be used
as identifiers.
Describe the purpose and use of each code segment and are ignored by
PL/SQL.
Building blocks of any PL/SQL block and are sequences of characters
including letters, digits, tabs, returns, and symbols.

A name, up to 30 characters in length, given to a PL/SQL object.

Copyright © 2019, Oracle and/or its affiliates. All rights reserved. Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners.
2

Try It / Solve It Questions


1. Identify each of the following identifiers as valid or invalid. If invalid, specify why.

Valid Invalid
Identifier Why Invalid?
(X) (X)

Today

Last name

today’s_date

number_of_days_in_february_this_ year

Isleap$year

#number

NUMBER#

Number1to7

2. Identify the reserved words in the following list.


Word Reserved? Y/N
create
make
table
seat
alter
rename
row
number
web

Copyright © 2019, Oracle and/or its affiliates. All rights reserved. Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective
owners.
3

3. What kind of lexical unit (for example Reserved word, Delimiter, Literal, Comment) is each of the
following?
Value Lexical Unit

SELECT

:=

'TEST'

FALSE

-- new process

FROM

/* select the country with the high-


est elevation */

v_test

4.09

Copyright © 2019, Oracle and/or its affiliates. All rights reserved. Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective
owners.

You might also like