0 votes
in PL/SQL by
Explain what Is The Difference Between Nested Tables And Varrays?

1 Answer

0 votes
by
Both nested tables and VARRAYs are collection types that can be stored in the database. They differ in two properties, bounding and sparsity. Bounding refers to the limit on the number of elements that a collection can have; whereas, sparsity means whether there can be gaps within the subscripts or not.

Nested tables are not bounded and can be sparse; whereas, VARRAYs are bounded and cannot be sparse. It means that VARRAYs have a limit on the number of elements and are bounded; whereas, nested tables does not have a limit on the number of elements and are unbounded. Nested tables can become sparse if elements are deleted; whereas, VARRAYs can never become sparse.
...