首先你需要定義一個數組類型,然後定義這個數組變量    
declare    
type a_type is table of number    
-- type a_type is array(10) of number    
-- 下面一種定義方式則指定了該數組的最大元素個數    
a a_type := a_type() -- 定義並初始化一個數組變量    
begin    
nd(3) -- 數組擴展到3個元素    
a(1) := 1    
a(2) := 10    
a(3) := 100    
end