increment function in plsql

2020-08-10 04:08发布

In most programming languages you have a fast way to write an increment for a variable like the following examples:

inc(variableName);
variableName++;
variableName += 1;

Which ways are there in Oracle Pl/Sql to do this instead of using the following:

variableName := variableName + 1;

1条回答
冷血范
2楼-- · 2020-08-10 04:54

The operators are listed in the documentation.

There is no equivalent of ++ or +=. I'm afraid you have to do it the long way.

You could write your own inc() function but that would probably make your code less readable to others as it would be non-standard.

查看更多
登录 后发表回答