Issue Details (XML | Word | Printable)

Key: CORE-4073
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Critical Critical
Assignee: Adriano dos Santos Fernandes
Reporter: Thomas Beckmann
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Firebird Core

Constant columns getting empty value with subselect from procedure

Created: 03/Apr/13 12:45 PM   Updated: 29/May/15 01:39 PM
Component/s: Engine
Affects Version/s: 3.0 Initial
Fix Version/s: 3.0 Alpha 1

Environment: Win7/64, version "WI-T3.0.0.30317 Firebird 3.0 Unstable"

QA Status: Done successfully


 Description  « Hide
Hard to describe, see this example:

set term ^ ;
create or alter procedure P_TEST returns (TEXT D_VC10) as
begin
  TEXT = '12345'; suspend;
end^
set term ; ^

select A, TEXT from (select 2 as A, TEXT from P_TEST);

returns

           A TEXT
============ ==========
           0 12345

and

select A, TEXT from (select '2' as A, TEXT from P_TEST);

returns

A TEXT
====== ==========
       12345


If the procedure is replaced like this

select A, TEXT from (select '2' as A, '12345' as TEXT from RDB$DATABASE);

everything works fine.

Queriing like this:

select A, TEXT from (select 2 as A, TEXT from P_TEST union select null, null from RDB$DATABASE where 1=0);

works, too.

(Of course the above stuff is a simplified test case)

 All   Comments   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Thomas Beckmann added a comment - 03/Apr/13 12:58 PM
(edited headline - first I though, it would happen inside SP or EB only)

Adriano dos Santos Fernandes added a comment - 03/Apr/13 03:29 PM
Please use "Affects version = 3.0 Initial" instead of 3.0 Alpha 1 (not yet released).

Thomas Beckmann added a comment - 03/Apr/13 03:44 PM
Sorry for using the wrong version - and thank you very much for your very fast reaction! I'm looking forward to get the snapshot tonight!