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

rdb$set_context does NOT allow to overwrite any vars after encountering limit (default=1000) of them [CORE2969] #3351

Closed
firebird-issue-importer opened this issue Apr 16, 2010 · 6 comments

Comments

@firebird-issue-importer

Submitted by: @pavel-zotov

Is related to QA278

It is impossible to OVERWRITE any of previously assigned context variable if the number of them reaches the hard-coded limit (1000).
The following code will finished Ok only for the FIRST run. The error "Too many context variables" will occur if we run it second time - even if the limit will be decreased:

execute block returns(was_overwritten int, ctx_key varchar(30), ctx_val varchar(30))
as
declare variable k int;
begin
k = 0;
while (k < 1000) do
begin
ctx_key = 'var_' || k;

was\_overwritten=rdb$set\_context\('USER\_SESSION', :ctx\_key, rand\(\)\);
ctx\_val = rdb$get\_context\('USER\_SESSION', :ctx\_key\);
suspend;

k = k \+ 1;

end
end

Commits: c07eebd FirebirdSQL/fbt-repository@2488814

@firebird-issue-importer
Copy link
Author

@firebird-issue-importer firebird-issue-importer commented Apr 16, 2010

Modified by: @hvlad

assignee: Vlad Khorsun [ hvlad ]

@firebird-issue-importer
Copy link
Author

@firebird-issue-importer firebird-issue-importer commented Apr 16, 2010

Commented by: @hvlad

The fix was backported from v2.5 where it was fixed already

@firebird-issue-importer
Copy link
Author

@firebird-issue-importer firebird-issue-importer commented Apr 16, 2010

Modified by: @hvlad

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

resolution: Fixed [ 1 ]

Fix Version: 2.1.4 [ 10361 ]

@firebird-issue-importer
Copy link
Author

@firebird-issue-importer firebird-issue-importer commented Feb 23, 2011

Modified by: @pcisar

Link: This issue is related to QA278 [ QA278 ]

@firebird-issue-importer
Copy link
Author

@firebird-issue-importer firebird-issue-importer commented Nov 28, 2013

Modified by: @pmakowski

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

@firebird-issue-importer
Copy link
Author

@firebird-issue-importer firebird-issue-importer commented Jul 20, 2015

Modified by: @pavel-zotov

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

QA Status: Done successfully

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants