conversion error from string "" when doing INNER JOIN with empty result set.
----------------------------------------------------------------------------
Key: CORE-4852
URL: http://tracker.firebirdsql.org/browse/CORE-4852
Project: Firebird Core
Issue Type: Bug
Components: Engine
Affects Versions: 2.5.4
Environment: Win 7 64 bit, Firebird 32 bit.
Reporter: Marcin
Create this procedure:
SET TERM ^ ;
CREATE PROCEDURE PROC_SPLIT_STRING (
P_STRING VARCHAR(32000),
P_SPLITTER CHAR(1) )
RETURNS (
PART VARCHAR(32000) )
AS
DECLARE VARIABLE LASTPOS INTEGER;
DECLARE VARIABLE NEXTPOS INTEGER;
BEGIN
PART ='';
SUSPEND;
END
^
SET TERM ; ^
Then perform this query:
SELECT
A.PART
FROM
(
SELECT
P.PART AS PART
FROM
PROC_SPLIT_STRING('', ',') P
WHERE
P.PART <> ''
) A
INNER JOIN
RDB$DATABASE R ON A.PART = 1
Engine returns an error: conversion error from string "". The problem is that
there are no rows in result set A. So query should return an empty result set
after joining A with R, instead error is returned indicating that A is not
empty and A.PART contains string in it.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://tracker.firebirdsql.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
------------------------------------------------------------------------------
Don't Limit Your Business. Reach for the Cloud.
GigeNET's Cloud Solutions provide you with the tools and support that
you need to offload your IT needs and focus on growing your business.
Configured For All Businesses. Start Your Cloud Today.
https://www.gigenetcloud.com/
Firebird-Devel mailing list, web interface at
https://lists.sourceforge.net/lists/listinfo/firebird-devel