Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some PSQL statements may lead to exceptions report wrong line/column [CORE6403] #6641

Closed
firebird-automations opened this issue Sep 20, 2020 · 5 comments

Comments

@firebird-automations
Copy link
Collaborator

Submitted by: @asfernandes

Example 1:

execute block
as
declare n integer = 0;
begin
while (1 / n > 0)
do
begin
n = n - 1;
end
end!

arithmetic exception, numeric overflow, or string truncation
-Integer divide by zero. The code attempted to divide an integer value by an integer divisor of zero.
-At block line: 5, col: 5

If initial value of N variable is changed to 1, then error is:

-At block line: 8, col: 9

-----------

Example 2:

execute block
as
declare n integer = 0;
declare x integer;
begin
for select 1 / :n from rdb$database union all select 1 / :n from rdb$database into x
do
begin
n = n - 1;
end
end!

arithmetic exception, numeric overflow, or string truncation
-Integer divide by zero. The code attempted to divide an integer value by an integer divisor of zero.
-At block line: 6, col: 5

If initial value of N variable is changed to 1, then error is:

-At block line: 9, col: 9

Commits: c499fb5

@firebird-automations
Copy link
Collaborator Author

Modified by: @asfernandes

assignee: Adriano dos Santos Fernandes [ asfernandes ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @asfernandes

summary: Some PSQL constructions may lead to exceptions report wrong line/column => Some PSQL statements may lead to exceptions report wrong line/column

@firebird-automations
Copy link
Collaborator Author

Modified by: @asfernandes

status: Open [ 1 ] => Resolved [ 5 ]

resolution: Fixed [ 1 ]

Fix Version: 4.0 RC 1 [ 10930 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

status: Resolved [ 5 ] => Resolved [ 5 ]

QA Status: No test => Done successfully

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

status: Resolved [ 5 ] => Closed [ 6 ]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment