powered by simpleCommunicator - 2.0.49     © 2025 Programmizd 02
Форумы / Informix [игнор отключен] [закрыт для гостей] / Нестандартное поведение FOR в SPL
1 сообщений из 1, страница 1 из 1
Нестандартное поведение FOR в SPL
    #36856676
victor16
Скрыть профиль Поместить в игнор-лист Сообщения автора в теме
Гость
The general form of the IDS SPL For loop is...
Код: plaintext
1.
2.
3.
4.
5.
FOR LoopVar = StartVal TO EndVal [ STEP StepVal]

-- statement block

END FOR;

The STEP clause is optional. If it is not provided, the StepVal defaults to 1, unless StartVal > EndVal, in which case it defaults to -1

All this is documented in http://publib.boulder.ibm.com/infocenter/idshelp/v115/index.jsp?topic=/com.ibm.sqls.doc/ids_sqs_1326.htm&resultof=%22%66%6f%72%22%22%6c%6f%6f%70%22

Please alter the SQL syntax documentation to more clearly describe the behavior of the "FOR" statement when the left_expression is numerically greater than the right_expression.
The documentation currently states:
"The size of right_expression relative to left_expression determines if the range is stepped through by positive or negative increments."

A suggested rewording is:
"If the STEP clause is not provided, the increment_expr will default to 1, unless left_expression > right_expression, in which case it will default to -1"
...
Рейтинг: 0 / 0
1 сообщений из 1, страница 1 из 1
Форумы / Informix [игнор отключен] [закрыт для гостей] / Нестандартное поведение FOR в SPL
Целевая тема:
Создать новую тему:
Автор:
Закрыть
Цитировать
Найденые пользователи ...
Разблокировать пользователей ...
Читали форум (0):
Пользователи онлайн (0):
x
x
Закрыть


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