[JBoss JIRA] (TEIID-2605) Optimization substitutes wrong column in where clause
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-2605?page=com.atlassian.jira.plugin... ]
Steven Hawkins closed TEIID-2605.
---------------------------------
> Optimization substitutes wrong column in where clause
> -----------------------------------------------------
>
> Key: TEIID-2605
> URL: https://issues.jboss.org/browse/TEIID-2605
> Project: Teiid
> Issue Type: Bug
> Components: Query Engine
> Affects Versions: 8.1
> Environment: z/OS
> Reporter: Jeff Hayes
> Assignee: Steven Hawkins
> Attachments: query_plan.txt, views.xml
>
>
> Optimization results in a query with a different column in the WHERE clause producing an empty result set.
> Full query plan is attached but the beginning and ending queries are shown below. Note that the subject column of the IN clause is SCOPEID but optimization changes it to AUTHID for some reason.
> USER COMMAND:
> SELECT * FROM SECURITY.SCPXREF AS CHORUS_B WHERE (CHORUS_B.SYSID = 'DE29') AND ((CHORUS_B.SCOPEID IN (SELECT SN5.SCOPEID FROM SECURI
> TY.SCPNEXT AS SN5 WHERE (SYSID = 'DE29') AND (NEXTREC IN (SELECT SN4.SCOPEID FROM SECURITY.SCPNEXT AS SN4 WHERE (SYSID = 'DE29') AND
> (NEXTREC IN (SELECT SN3.SCOPEID FROM SECURITY.SCPNEXT AS SN3 WHERE (SYSID = 'DE29') AND (NEXTREC IN (SELECT SN2.SCOPEID FROM SECURI
> TY.SCPNEXT AS SN2 WHERE (SYSID = 'DE29') AND (NEXTREC = 'CHRDEPT1'))))))))) OR (CHORUS_B.SCOPEID IN (SELECT SN4.SCOPEID FROM SECURIT
> Y.SCPNEXT AS SN4 WHERE (SYSID = 'DE29') AND (NEXTREC IN (SELECT SN3.SCOPEID FROM SECURITY.SCPNEXT AS SN3 WHERE (SYSID = 'DE29') AND
> (NEXTREC IN (SELECT SN2.SCOPEID FROM SECURITY.SCPNEXT AS SN2 WHERE (SYSID = 'DE29') AND (NEXTREC = 'CHRDEPT1'))))))) OR (CHORUS_B.SC
> OPEID IN (SELECT SN3.SCOPEID FROM SECURITY.SCPNEXT AS SN3 WHERE (SYSID = 'DE29') AND (NEXTREC IN (SELECT SN2.SCOPEID FROM SECURITY.S
> CPNEXT AS SN2 WHERE (SYSID = 'DE29') AND (NEXTREC = 'CHRDEPT1'))))) OR (CHORUS_B.SCOPEID IN (SELECT SN2.SCOPEID FROM SECURITY.SCPNEX
> T AS SN2 WHERE (SYSID = 'DE29') AND (NEXTREC = 'CHRDEPT1'))) OR (CHORUS_B.SCOPEID = 'CHRDEPT1'))
> OPTIMIZATION COMPLETE:
> PROCESSOR PLAN:
> AccessNode(10) output=[x.sysid AS sysid, x.scopeid AS authid, x.authid AS scopeid, x.authtype AS authtype] SELECT g_0.SYSID, g_0.SCO
> PEID, g_0.AUTHID, g_0.AUTHTYPE FROM SECURITY_CIA_DB2_D91BPTIB_CIADB01.SCPXREF AS g_0 WHERE (g_0.SYSID = 'DE29') AND ((g_0.AUTHID IN
> (SELECT g_1.SCOPEID FROM SECURITY_CIA_DB2_D91BPTIB_CIADB01.SCPNEXT AS g_1 WHERE (g_1.SYSID = 'DE29') AND (g_1.NEXTREC IN (SELECT g_2
> .SCOPEID FROM SECURITY_CIA_DB2_D91BPTIB_CIADB01.SCPNEXT AS g_2 WHERE (g_2.SYSID = 'DE29') AND (g_2.NEXTREC IN (SELECT g_3.SCOPEID FR
> OM SECURITY_CIA_DB2_D91BPTIB_CIADB01.SCPNEXT AS g_3 WHERE (g_3.SYSID = 'DE29') AND (g_3.NEXTREC IN (SELECT g_4.SCOPEID FROM SECURITY
> _CIA_DB2_D91BPTIB_CIADB01.SCPNEXT AS g_4 WHERE (g_4.SYSID = 'DE29') AND (g_4.NEXTREC = 'CHRDEPT1'))))))))) OR (g_0.AUTHID IN (SELECT
> g_5.SCOPEID FROM SECURITY_CIA_DB2_D91BPTIB_CIADB01.SCPNEXT AS g_5 WHERE (g_5.SYSID = 'DE29') AND (g_5.NEXTREC IN (SELECT g_6.SCOPEI
> D FROM SECURITY_CIA_DB2_D91BPTIB_CIADB01.SCPNEXT AS g_6 WHERE (g_6.SYSID = 'DE29') AND (g_6.NEXTREC IN (SELECT g_7.SCOPEID FROM SECU
> RITY_CIA_DB2_D91BPTIB_CIADB01.SCPNEXT AS g_7 WHERE (g_7.SYSID = 'DE29') AND (g_7.NEXTREC = 'CHRDEPT1'))))))) OR (g_0.AUTHID IN (SELE
> CT g_8.SCOPEID FROM SECURITY_CIA_DB2_D91BPTIB_CIADB01.SCPNEXT AS g_8 WHERE (g_8.SYSID = 'DE29') AND (g_8.NEXTREC IN (SELECT g_9.SCOP
> EID FROM SECURITY_CIA_DB2_D91BPTIB_CIADB01.SCPNEXT AS g_9 WHERE (g_9.SYSID = 'DE29') AND (g_9.NEXTREC = 'CHRDEPT1'))))) OR (g_0.AUTH
> ID IN (SELECT g_10.SCOPEID FROM SECURITY_CIA_DB2_D91BPTIB_CIADB01.SCPNEXT AS g_10 WHERE (g_10.SYSID = 'DE29') AND (g_10.NEXTREC = 'C
> HRDEPT1'))) OR (g_0.AUTHID = 'CHRDEPT1'))
> The view definitions are shown below:
> <view name="SCPNEXT">
> <columns>
> <column name="sysid" type="varchar"/>
> <column name="scopeid" type="varchar"/>
> <column name="nextrec" type="varchar"/>
> </columns>
> <definition>
> #if ($db.count("select count(*) from sys.tables where Name='config' and SchemaName = 'security_db'") > 0)
> #set ($count = 0)
> #foreach($t in $db.query("select DB_TYPE, DB_LOC, DB_QUAL from security_db.config WHERE TYPE = 'CIA'"))
> #if ($db.count("select count(*) from sys.tables where SchemaName = 'SECURITY_CIA_${t.DB_TYPE}_${t.DB_LOC}_${t.DB_QUAL}'") == 0)
> #set ($count = $count + 1)
> #end
> #end
> #if ($count == 0)
> SELECT t.sysid, t.scopeid, t.nextrec
> FROM (
> #foreach($t in $db.query("select DB_TYPE, DB_LOC, DB_QUAL from security_db.config WHERE TYPE = 'CIA'"))
> SELECT n.sysid, n.scopeid, n.nextrec
> FROM SECURITY_CIA_${t.DB_TYPE}_${t.DB_LOC}_${t.DB_QUAL}.SCPNEXT n
> #if( $velocityHasNext ) UNION #end
> #end
> ) AS t
> #end
> #end
> </definition>
> </view>
> <view name="SCPXREF">
> <columns>
> <column name="sysid" type="varchar"/>
> <column name="authid" type="varchar"/>
> <column name="scopeid" type="varchar"/>
> <column name="authtype" type="varchar"/>
> </columns>
> <definition>
> #if ($db.count("select count(*) from sys.tables where Name='config' and SchemaName = 'security_db'") > 0)
> #set ($count = 0)
> #foreach($t in $db.query("select DB_TYPE, DB_LOC, DB_QUAL from security_db.config WHERE TYPE = 'CIA'"))
> #if ($db.count("select count(*) from sys.tables where SchemaName = 'SECURITY_CIA_${t.DB_TYPE}_${t.DB_LOC}_${t.DB_QUAL}'") == 0)
> #set ($count = $count + 1)
> #end
> #end
> #if ($count == 0)
> SELECT sysid, scopeid, authid, authtype
> FROM (
> #foreach($t in $db.query("select DB_TYPE, DB_LOC, DB_QUAL from security_db.config WHERE TYPE = 'CIA'"))
> SELECT x.sysid, x.scopeid, x.authid, x.authtype
> FROM SECURITY_CIA_${t.DB_TYPE}_${t.DB_LOC}_${t.DB_QUAL}.SCPXREF x
> #if( $velocityHasNext ) UNION #end
> #end
> ) AS t
> #end
> #end
> </definition>
> </view>
> I guess the best way to test this is to define these views and run the input query with SHOWPLAN=DEBUG and see if the AUTHID substitution is occurring.
> Thanks!
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
2 weeks, 6 days
[JBoss JIRA] (TEIID-5924) Salesforce: UPDATE doesn't work when setting null values
by Steven Hawkins (Jira)
[ https://issues.redhat.com/browse/TEIID-5924?page=com.atlassian.jira.plugi... ]
Steven Hawkins resolved TEIID-5924.
-----------------------------------
Resolution: Done
Updated the resource adapter to use the fieldsToNull property. Will need to work the common logic issue before this is picked up by teiid spring boot.
> Salesforce: UPDATE doesn't work when setting null values
> --------------------------------------------------------
>
> Key: TEIID-5924
> URL: https://issues.redhat.com/browse/TEIID-5924
> Project: Teiid
> Issue Type: Bug
> Components: Salesforce Connector
> Affects Versions: 13.1
> Reporter: Dmitrii Pogorelov
> Assignee: Steven Hawkins
> Priority: Blocker
> Fix For: 14.0, 13.0.3, 13.1.1
>
> Original Estimate: 4 hours
> Remaining Estimate: 4 hours
>
> UPDATE command doesn't work when setting null values:
> {code:sql}
> select w.* from (call sf34.native('update;type=Contact;attributes=id, OwnerId, LastName, Birthdate', '0031Y000062bY4aQAE', '005i0000002dtHTAAY', 'test_updates_null', null)) as w ;;
>
> update sf34.Contact set Birthdate = null where LastName = 'test_updates_null' ;;
> {code}
> queries do nothing. The query:
> {code:sql}
> select OwnerId, LastName, Birthdate from sf34.Contact where LastName = 'test_updates_null' ;;
> {code}
> will return the same result as before running these UPDATE commands.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years, 7 months
[JBoss JIRA] (TEIID-5924) Salesforce: UPDATE doesn't work when setting null values
by Steven Hawkins (Jira)
[ https://issues.redhat.com/browse/TEIID-5924?focusedWorklogId=12450697&pag... ]
Steven Hawkins logged work on TEIID-5924:
-----------------------------------------
Author: Steven Hawkins
Created on: 31/Mar/20 3:29 PM
Start Date: 31/Mar/20 3:29 PM
Worklog Time Spent: 4 hours
Issue Time Tracking
-------------------
Remaining Estimate: 0 minutes (was: 4 hours)
Time Spent: 4 hours
Worklog Id: (was: 12450697)
> Salesforce: UPDATE doesn't work when setting null values
> --------------------------------------------------------
>
> Key: TEIID-5924
> URL: https://issues.redhat.com/browse/TEIID-5924
> Project: Teiid
> Issue Type: Bug
> Components: Salesforce Connector
> Affects Versions: 13.1
> Reporter: Dmitrii Pogorelov
> Assignee: Steven Hawkins
> Priority: Blocker
> Fix For: 14.0, 13.0.3, 13.1.1
>
> Original Estimate: 4 hours
> Time Spent: 4 hours
> Remaining Estimate: 0 minutes
>
> UPDATE command doesn't work when setting null values:
> {code:sql}
> select w.* from (call sf34.native('update;type=Contact;attributes=id, OwnerId, LastName, Birthdate', '0031Y000062bY4aQAE', '005i0000002dtHTAAY', 'test_updates_null', null)) as w ;;
>
> update sf34.Contact set Birthdate = null where LastName = 'test_updates_null' ;;
> {code}
> queries do nothing. The query:
> {code:sql}
> select OwnerId, LastName, Birthdate from sf34.Contact where LastName = 'test_updates_null' ;;
> {code}
> will return the same result as before running these UPDATE commands.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years, 7 months
[JBoss JIRA] (TEIID-5924) Salesforce: UPDATE doesn't work when setting null values
by Steven Hawkins (Jira)
[ https://issues.redhat.com/browse/TEIID-5924?page=com.atlassian.jira.plugi... ]
Steven Hawkins updated TEIID-5924:
----------------------------------
Fix Version/s: 14.0
13.0.3
13.1.1
Original Estimate: 4 hours
Remaining Estimate: 4 hours
Story Points: 0.5
Sprint: DV Sprint 59
Priority: Blocker (was: Critical)
There is nuance to the salesforce api that requires null values to be handled via a special fieldsToNull that was unaccounted for.
> Salesforce: UPDATE doesn't work when setting null values
> --------------------------------------------------------
>
> Key: TEIID-5924
> URL: https://issues.redhat.com/browse/TEIID-5924
> Project: Teiid
> Issue Type: Bug
> Components: Salesforce Connector
> Affects Versions: 13.1
> Reporter: Dmitrii Pogorelov
> Assignee: Steven Hawkins
> Priority: Blocker
> Fix For: 14.0, 13.0.3, 13.1.1
>
> Original Estimate: 4 hours
> Remaining Estimate: 4 hours
>
> UPDATE command doesn't work when setting null values:
> {code:sql}
> select w.* from (call sf34.native('update;type=Contact;attributes=id, OwnerId, LastName, Birthdate', '0031Y000062bY4aQAE', '005i0000002dtHTAAY', 'test_updates_null', null)) as w ;;
>
> update sf34.Contact set Birthdate = null where LastName = 'test_updates_null' ;;
> {code}
> queries do nothing. The query:
> {code:sql}
> select OwnerId, LastName, Birthdate from sf34.Contact where LastName = 'test_updates_null' ;;
> {code}
> will return the same result as before running these UPDATE commands.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years, 7 months
[JBoss JIRA] (TEIID-5924) Salesforce: UPDATE doesn't work when setting null values
by Dmitrii Pogorelov (Jira)
Dmitrii Pogorelov created TEIID-5924:
----------------------------------------
Summary: Salesforce: UPDATE doesn't work when setting null values
Key: TEIID-5924
URL: https://issues.redhat.com/browse/TEIID-5924
Project: Teiid
Issue Type: Bug
Components: Salesforce Connector
Affects Versions: 13.1
Reporter: Dmitrii Pogorelov
Assignee: Steven Hawkins
UPDATE command doesn't work when setting null values:
{code:sql}
select w.* from (call sf34.native('update;type=Contact;attributes=id, OwnerId, LastName, Birthdate', '0031Y000062bY4aQAE', '005i0000002dtHTAAY', 'test_updates_null', null)) as w ;;
update sf34.Contact set Birthdate = null where LastName = 'test_updates_null' ;;
{code}
queries do nothing. The query:
{code:sql}
select OwnerId, LastName, Birthdate from sf34.Contact where LastName = 'test_updates_null' ;;
{code}
will return the same result as before running these UPDATE commands.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years, 7 months
[JBoss JIRA] (TEIID-5924) Salesforce: UPDATE doesn't work when setting null values
by Dmitrii Pogorelov (Jira)
[ https://issues.redhat.com/browse/TEIID-5924?page=com.atlassian.jira.plugi... ]
Dmitrii Pogorelov commented on TEIID-5924:
------------------------------------------
[~shawkins] a follow-up ticket for TEIID-5923 issue.
> Salesforce: UPDATE doesn't work when setting null values
> --------------------------------------------------------
>
> Key: TEIID-5924
> URL: https://issues.redhat.com/browse/TEIID-5924
> Project: Teiid
> Issue Type: Bug
> Components: Salesforce Connector
> Affects Versions: 13.1
> Reporter: Dmitrii Pogorelov
> Assignee: Steven Hawkins
> Priority: Critical
>
> UPDATE command doesn't work when setting null values:
> {code:sql}
> select w.* from (call sf34.native('update;type=Contact;attributes=id, OwnerId, LastName, Birthdate', '0031Y000062bY4aQAE', '005i0000002dtHTAAY', 'test_updates_null', null)) as w ;;
>
> update sf34.Contact set Birthdate = null where LastName = 'test_updates_null' ;;
> {code}
> queries do nothing. The query:
> {code:sql}
> select OwnerId, LastName, Birthdate from sf34.Contact where LastName = 'test_updates_null' ;;
> {code}
> will return the same result as before running these UPDATE commands.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years, 7 months
[JBoss JIRA] (TEIID-5923) Salesforce: UPDATE fails for BOOLEAN and DATE fields
by Dmitrii Pogorelov (Jira)
[ https://issues.redhat.com/browse/TEIID-5923?page=com.atlassian.jira.plugi... ]
Dmitrii Pogorelov commented on TEIID-5923:
------------------------------------------
[~shawkins] thx a lot for the quick fix, it helped!
> Salesforce: UPDATE fails for BOOLEAN and DATE fields
> ----------------------------------------------------
>
> Key: TEIID-5923
> URL: https://issues.redhat.com/browse/TEIID-5923
> Project: Teiid
> Issue Type: Bug
> Components: Salesforce Connector
> Affects Versions: 13.1
> Reporter: Dmitrii Pogorelov
> Assignee: Steven Hawkins
> Priority: Critical
> Fix For: 14.0, 13.1.1
>
>
> 1. Running the following queries:
> {code:sql}
> --1.1 Update some BOOLEAN field and check if it's value changed (it should).
> --Error: TEIID30504 Remote org.teiid.core.TeiidProcessingException: TEIID30504 sf34: bo: value not of required type: FALSE
> update sf34.test_type__c set bo__c = false where str__c = 'test_updates' ;;
>
> --1.2 Error: TEIID30504 Remote org.teiid.core.TeiidProcessingException: TEIID30504 sf34: bo: value not of required type: FALSE
> update sf34.test_type__c set bo__c = false ;;
> {code}
> will lead to the following error:
> {code}
> 2020-03-26 16:49:42,926 WARN [org.teiid.CONNECTOR] (Worker3_QueryProcessorQueue15) 1yWWIDJQwoJo Connector worker process failed for atomic-request=1yWWIDJQwoJo.3.0.3: org.teiid.translator.TranslatorException: bo: value not of required type: FALSE at org.teiid.resource.adapter.salesforce.SalesforceConnectionImpl.analyzeResult(SalesforceConnectionImpl.java:431) at org.teiid.resource.adapter.salesforce.SalesforceConnectionImpl.update(SalesforceConnectionImpl.java:425) at org.teiid.translator.salesforce.execution.UpdateExecutionImpl.processIds(UpdateExecutionImpl.java:74) at org.teiid.translator.salesforce.execution.AbstractUpdateExecution.execute(AbstractUpdateExecution.java:124) at org.teiid.translator.salesforce.execution.UpdateExecutionImpl.execute(UpdateExecutionImpl.java:51) at org.teiid.dqp.internal.datamgr.ConnectorWorkItem$1.execute(ConnectorWorkItem.java:443) at org.teiid.dqp.internal.datamgr.ConnectorWorkItem.execute(ConnectorWorkItem.java:402) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.teiid.dqp.internal.datamgr.ConnectorManager$1.invoke(ConnectorManager.java:228) at com.sun.proxy.$Proxy44.execute(Unknown Source) at org.teiid.dqp.internal.process.DataTierTupleSource.getResults(DataTierTupleSource.java:302) at org.teiid.dqp.internal.process.DataTierTupleSource$1.call(DataTierTupleSource.java:108) at org.teiid.dqp.internal.process.DataTierTupleSource$1.call(DataTierTupleSource.java:104) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at org.teiid.dqp.internal.process.FutureWork.run(FutureWork.java:59) at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:281) at org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:124) at org.teiid.dqp.internal.process.ThreadReuseExecutor$2.run(ThreadReuseExecutor.java:212) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745)
> {code}
> {code:sql}
> --1.3 DEFECT(value has not changed)
> select OwnerId, bo__c, str__c from sf34.test_type__c where str__c = 'test_updates' ;;
> {code}
> 2. Running the following queries:
> {code:sql}
> --2.1 Insert some value into BOOLEAN field and check if it's there (it should be).
> --Error: TEIID30504 Remote org.teiid.core.TeiidProcessingException: TEIID30504 sf34: bo: value not of required type: true
> select w.* from (call sf34.native('create;type=test_type__c;attributes=OwnerId, bo__c, str__c', '005i0000002dtHTAAY', true, 'test_updates')) as w ;;
> {code}
> will lead to the following error:
> {code}
> 2020-03-26 16:53:31,525 WARN [org.teiid.CONNECTOR] (Worker5_QueryProcessorQueue29) 1yWWIDJQwoJo Connector worker process failed for atomic-request=1yWWIDJQwoJo.7.3.7: org.teiid.translator.TranslatorException: bo: value not of required type: true at org.teiid.resource.adapter.salesforce.SalesforceConnectionImpl.analyzeResult(SalesforceConnectionImpl.java:431) at org.teiid.resource.adapter.salesforce.SalesforceConnectionImpl.create(SalesforceConnectionImpl.java:396) at org.teiid.translator.salesforce.execution.DirectQueryExecution.doInsert(DirectQueryExecution.java:133) at org.teiid.translator.salesforce.execution.DirectQueryExecution.execute(DirectQueryExecution.java:97) at org.teiid.dqp.internal.datamgr.ConnectorWorkItem.execute(ConnectorWorkItem.java:402) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.teiid.dqp.internal.datamgr.ConnectorManager$1.invoke(ConnectorManager.java:228) at com.sun.proxy.$Proxy44.execute(Unknown Source) at org.teiid.dqp.internal.process.DataTierTupleSource.getResults(DataTierTupleSource.java:302) at org.teiid.dqp.internal.process.DataTierTupleSource$1.call(DataTierTupleSource.java:108) at org.teiid.dqp.internal.process.DataTierTupleSource$1.call(DataTierTupleSource.java:104) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at org.teiid.dqp.internal.process.FutureWork.run(FutureWork.java:59) at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:281) at org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:124) at org.teiid.dqp.internal.process.ThreadReuseExecutor$2.run(ThreadReuseExecutor.java:212) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745)
> {code}
> {code:sql}
> --2.2 DEFECT(value has not changed)
> select OwnerId, bo__c, str__c from sf34.test_type__c where str__c = 'test_updates' ;;
> {code}
> 3. Running the following queries:
> {code:sql}
> --3.1 Update some DATE field and check if it's value changed (it should).
> --Error: TEIID30504 Remote org.teiid.core.TeiidProcessingException: TEIID30504 sf34: Birthdate: value not of required type: {d '2002-11-11'}
> update sf34.Contact set Birthdate = '2002-11-11' where LastName = 'test_updates' ;;
>
> --3.2 Error: TEIID30504 Remote org.teiid.core.TeiidProcessingException: TEIID30504 sf34: Birthdate: value not of required type: {d '2002-11-11'}
> update sf34.Contact set Birthdate = cast('2002-11-11' as date) where LastName = 'test_updates' ;;
> {code}
> will lead to the following error:
> {code}
> 2020-03-26 16:56:03,868 WARN [org.teiid.CONNECTOR] (Worker5_QueryProcessorQueue42) 1yWWIDJQwoJo Connector worker process failed for atomic-request=1yWWIDJQwoJo.11.0.11: org.teiid.translator.TranslatorException: Birthdate: value not of required type: {d '2002-11-11'} at org.teiid.resource.adapter.salesforce.SalesforceConnectionImpl.analyzeResult(SalesforceConnectionImpl.java:431) at org.teiid.resource.adapter.salesforce.SalesforceConnectionImpl.update(SalesforceConnectionImpl.java:425) at org.teiid.translator.salesforce.execution.UpdateExecutionImpl.processIds(UpdateExecutionImpl.java:74) at org.teiid.translator.salesforce.execution.AbstractUpdateExecution.execute(AbstractUpdateExecution.java:124) at org.teiid.translator.salesforce.execution.UpdateExecutionImpl.execute(UpdateExecutionImpl.java:51) at org.teiid.dqp.internal.datamgr.ConnectorWorkItem$1.execute(ConnectorWorkItem.java:443) at org.teiid.dqp.internal.datamgr.ConnectorWorkItem.execute(ConnectorWorkItem.java:402) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.teiid.dqp.internal.datamgr.ConnectorManager$1.invoke(ConnectorManager.java:228) at com.sun.proxy.$Proxy44.execute(Unknown Source) at org.teiid.dqp.internal.process.DataTierTupleSource.getResults(DataTierTupleSource.java:302) at org.teiid.dqp.internal.process.DataTierTupleSource$1.call(DataTierTupleSource.java:108) at org.teiid.dqp.internal.process.DataTierTupleSource$1.call(DataTierTupleSource.java:104) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at org.teiid.dqp.internal.process.FutureWork.run(FutureWork.java:59) at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:281) at org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:124) at org.teiid.dqp.internal.process.ThreadReuseExecutor$2.run(ThreadReuseExecutor.java:212) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745)
> {code}
> {code:sql}
> --3.3 DEFECT(value has not changed)
> select OwnerId, LastName, Birthdate from sf34.Contact where LastName = 'test_updates' ;;
> {code}
> 4. Running the following queries:
> {code:sql}
> --4.1 Insert some value into DATE field and check if it's there (it should be).
> --Error: TEIID30504 Remote org.teiid.core.TeiidProcessingException: TEIID30504 sf34: Birthdate: value not of required type: 2020-03-22
> select w.* from (call sf34.native('create;type=Contact;attributes=OwnerId, LastName, Birthdate', '005i0000002dtHTAAY', 'test_updates', '2020-03-22')) as w ;;
>
> --4.2 Error: TEIID30504 Remote org.teiid.core.TeiidProcessingException: TEIID30504 sf34: Birthdate: value not of required type: 2020-03-22
> select w.* from (call sf34.native('create;type=Contact;attributes=OwnerId, LastName, Birthdate', '005i0000002dtHTAAY', 'test_updates', cast('2020-03-22' as date)) ) as w ;;
> {code}
> will lead to the following error:
> {code}
> 2020-03-26 16:57:49,333 WARN [org.teiid.CONNECTOR] (Worker5_QueryProcessorQueue51) 1yWWIDJQwoJo Connector worker process failed for atomic-request=1yWWIDJQwoJo.14.3.14: org.teiid.translator.TranslatorException: Birthdate: value not of required type: 2020-03-22 at org.teiid.resource.adapter.salesforce.SalesforceConnectionImpl.analyzeResult(SalesforceConnectionImpl.java:431) at org.teiid.resource.adapter.salesforce.SalesforceConnectionImpl.create(SalesforceConnectionImpl.java:396) at org.teiid.translator.salesforce.execution.DirectQueryExecution.doInsert(DirectQueryExecution.java:133) at org.teiid.translator.salesforce.execution.DirectQueryExecution.execute(DirectQueryExecution.java:97) at org.teiid.dqp.internal.datamgr.ConnectorWorkItem.execute(ConnectorWorkItem.java:402) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.teiid.dqp.internal.datamgr.ConnectorManager$1.invoke(ConnectorManager.java:228) at com.sun.proxy.$Proxy44.execute(Unknown Source) at org.teiid.dqp.internal.process.DataTierTupleSource.getResults(DataTierTupleSource.java:302) at org.teiid.dqp.internal.process.DataTierTupleSource$1.call(DataTierTupleSource.java:108) at org.teiid.dqp.internal.process.DataTierTupleSource$1.call(DataTierTupleSource.java:104) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at org.teiid.dqp.internal.process.FutureWork.run(FutureWork.java:59) at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:281) at org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:124) at org.teiid.dqp.internal.process.ThreadReuseExecutor$2.run(ThreadReuseExecutor.java:212) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745)
> {code}
> {code:sql}
> --4.3 DEFECT(value has not changed)
> select OwnerId, LastName, Birthdate from sf34.Contact where LastName = 'test_updates' ;;
> {code}
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years, 7 months
[JBoss JIRA] (TEIIDSB-182) Master teiid spring boot doc varient should not reference the ws translator
by Steven Hawkins (Jira)
[ https://issues.redhat.com/browse/TEIIDSB-182?page=com.atlassian.jira.plug... ]
Steven Hawkins resolved TEIIDSB-182.
------------------------------------
Resolution: Done
Updated the docs to reference both rest and soap for spring. The soap translator page still identifies it is known as the ws translator.
> Master teiid spring boot doc varient should not reference the ws translator
> ---------------------------------------------------------------------------
>
> Key: TEIIDSB-182
> URL: https://issues.redhat.com/browse/TEIIDSB-182
> Project: Teiid Spring Boot
> Issue Type: Bug
> Components: documentation
> Reporter: Steven Hawkins
> Assignee: Steven Hawkins
> Priority: Major
> Fix For: 1.5.0
>
> Original Estimate: 3 hours
> Remaining Estimate: 3 hours
>
> Specifically for Teiid Spring Boot we need to change references to the ws translator to the rest and soap translators. Additionally the rest translator adds support for a springHttp call
> - [~rareddy] can you describe why that was added?
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years, 7 months