powered by simpleCommunicator - 2.0.61     © 2026 Programmizd 02
Целевая тема:
Создать новую тему:
Автор:
Закрыть
Цитировать
Форумы / Oracle [игнор отключен] [закрыт для гостей] / Ограничение на размер пакета
4 сообщений из 4, страница 1 из 1
Ограничение на размер пакета
    #32171293
Speaker
Скрыть профиль Поместить в игнор-лист Сообщения автора в теме
Участник
Подскажите, имеется ли ограничение на размер тела пакета.\r
У меня сейчас он 1500 строк.\r
Для девятки вроде прокатывает, все нормально, но мне \r
предстоит перенести все это на 8.1.7 после выходных.\r
Почитал здесь, но не совсем понятно, где можно узнать подробнее?
...
Рейтинг: 0 / 0
Ограничение на размер пакета
    #32171308
Фотография SY
Скрыть профиль Поместить в игнор-лист Сообщения автора в теме
Участник
Well, there are several types of limits you can hit:

1. Source code size.
Source code size is almost never an issue. Starting with 8.1.3 package bodies and type bodies can have approximately up to about 6,000,000 lines of code.

2. DIANA limit.
When you compile source, Oracle produces pcode (pre-digested version of the PL/SQL source code) and then mcode (executable code) which is stored in DIANA:

"Oracle's PL/SQL programming language is based upon the ADA programming language. As a result, PL/SQL uses a variant of Descriptive Intermediate Attributed Notation for Ada (DIANA), which is a tree-structured intermediate language. It is defined using a meta-notation called Interface Definition Language (IDL). DIANA provides for communication internal to compilers and other tools. PL/SQL source code for a procedure or a package is stored in the database using the following two constructs:
o m-code
o DIANA
The m-code is the actual executable, while the DIANA provides source code dependency trees. At runtime, the m-code and DIANA are loaded into the shared pool. The m-code is the executable, while the DIANA compiles dependent procedures".
I do not know about 9i, but according to 8.1.6 documentation the following size limits apply:
"In the shared pool, a package spec, object type spec, stand-alone subprogram, or anonymous block is limited to 64K DIANA nodes. The nodes correspond to tokens such as identifiers, keywords, operators, and so on. The m-code is limited to 64K compiler-generated temporary variables." Although the PL/SQL compiler enforces its own size limits (listed below), usually it is the DIANA size limits which are reached first.
The following can be found in Appendix E of the "PL/SQL Users Guide and Reference 8.1.6 Release": Table E-1 PL/SQL Compiler Limits (8.1.X release)
Код: plaintext
1.
2.
3.
4.
5.
6.
7.
8.
9.
10.
11.
12.
13.
14.
15.
16.
17.
18.
19.
20.
21.
22.
23.
24.
25.
26.
27.
28.
Item                                                            Limit
bind variables passed to a program unit                         32K
exception handlers in a program unit                            64K    
fields in a record                                              64K    
levels of block nesting                                          255     
levels of record nesting                                          32     
levels of subquery nesting                                       254     
levels of label nesting                                           98     
magnitude of a BINARY_INTEGER value                              2G    
magnitude of a PLS_INTEGER value                                 2G    
objects referenced by a program unit                            64K    
parameters passed to an explicit cursor                         64K    
parameters passed to a function or procedure                    64K    
precision of a FLOAT value (binary digits)                       126     
precision of a NUMBER value (decimal digits)                      38     
precision of a REAL value (binary digits)                         63     
size of an identifier (characters)                                30     
size of a string literal (bytes)                                32K    
size of a CHAR value (bytes)                                    32K    
size of a LONG value (bytes)                                    32K -  7     
size of a LONG RAW value (bytes)                                32K -  7     
size of a RAW value (bytes)                                     32K    
size of a VARCHAR2 value (bytes)                                32K    
size of an NCHAR value (bytes)                                  32K    
size of an NVARCHAR2 value (bytes)                              32K    
size of a BIFLE value (bytes)                                    4G    
size of a BLOB value (bytes)                                     4G    
size of a CLOB value (bytes)                                     4G    
size of an NCLOB value (bytes)                                   4G   


SY
...
Рейтинг: 0 / 0
Ограничение на размер пакета
    #32171309
Фотография SY
Скрыть профиль Поместить в игнор-лист Сообщения автора в теме
Участник
One more thing:

Starting with release 7.2, the DIANA for package bodies is thrown away, not used, and not stored in the database. Therefore, large procedures and functions should always be defined within packages.

SY.
...
Рейтинг: 0 / 0
Ограничение на размер пакета
    #32171313
Speaker
Скрыть профиль Поместить в игнор-лист Сообщения автора в теме
Участник
Спасибо.
...
Рейтинг: 0 / 0
4 сообщений из 4, страница 1 из 1
Форумы / Oracle [игнор отключен] [закрыт для гостей] / Ограничение на размер пакета
Найденые пользователи ...
Разблокировать пользователей ...
Читали форум (0):
Пользователи онлайн (0):
x
x
Закрыть


Просмотр
0 / 0
Close
Debug Console [Select Text]