]
RH Bugzilla Integration commented on TEIID-5067:
------------------------------------------------
Jan Stastny <jstastny(a)redhat.com> changed the Status of [bug
Incorrect source query with simple inherent updates
---------------------------------------------------
Key: TEIID-5067
URL:
https://issues.jboss.org/browse/TEIID-5067
Project: Teiid
Issue Type: Bug
Components: JDG Connector, Misc. Connectors
Affects Versions: 8.12.x-6.4
Reporter: Jan Stastny
Assignee: Steven Hawkins
Priority: Critical
Fix For: 10.0, 8.12.x-6.4, 9.2.6, 9.3.4
A delete query against a view fails, when in WHERE clause there is a filter on
non-directly mapped column. Please note, that the integer type is only example, this
happens for any type (time/date/timestamp amongst other).
{code}
CREATE FOREIGN TABLE SmallA (
IntValue string,
StringKey string PRIMARY KEY
) OPTIONS(UPDATABLE true);
CREATE VIEW VSmallA(
IntValue integer,
StringKey string PRIMARY KEY
) OPTIONS (UPDATABLE true) AS
SELECT
CONVERT(source.IntValue,integer), source.StringKey FROM Source.SmallA as
source;
{code}
And following queries:
{code:sql|title=DELETE query}
DELETE FROM VSmallA WHERE IntValue=13
UPDATE VSmallA Set StringKey='a' WHERE IntValue=13
{code}
I get an incorrect source query with x.intvalue in the predicate.