Author |
Message
|
grasher134 |
Posted: Wed Oct 22, 2014 2:37 am Post subject: Failure in ESQL query. |
|
|
Acolyte
Joined: 22 Oct 2014 Posts: 62
|
At first, sorry for my English. Trying to perform a simple query with one dynamic parameter.
Code: |
SET Environment.Variables.DBResult = THE(SELECT a.cust_ac_no FROM Database.brsliveread.sttm_cust_account AS a WHERE a.alt_ac_no = ACC);
|
Where ACC is CHAR. This version works perfectly. Field in database has VARCHAR(20) type. Data in ACC field is something like '1234541545154'.
Code: |
SET Environment.Variables.DBResult = THE(SELECT a.cust_ac_no FROM Database.brsliveread.sttm_cust_account AS a WHERE a.alt_ac_no = '1234541545154'); |
Here is exception list.
Code: |
ExceptionList
RecoverableException
File:CHARACTER:F:\build\slot2\S000_P\src\DataFlowEngine\MessageServices\ImbDataFlowNode.cpp
Line:INTEGER:1153
Function:CHARACTER:ImbDataFlowNode::createExceptionList
Type:CHARACTER:ComIbmComputeNode
Name:CHARACTER:QueryCustAcc#FCMComposite_1_6
Label:CHARACTER:QueryCustAcc.FLEXCUBEXML
Catalog:CHARACTER:BIPmsgs
Severity:INTEGER:3
Number:INTEGER:2230
Text:CHARACTER:Node throwing exception
RecoverableException
File:CHARACTER:F:\build\slot2\S000_P\src\DataFlowEngine\ImbRdl\ImbRdlStatementGroup.cpp
Line:INTEGER:650
Function:CHARACTER:SqlStatementGroup::execute
Type:CHARACTER:
Name:CHARACTER:
Label:CHARACTER:
Catalog:CHARACTER:BIPmsgs
Severity:INTEGER:3
Number:INTEGER:2488
Text:CHARACTER:Error detected, rethrowing
Insert
Type:INTEGER:5
Text:CHARACTER:.QueryCustAcc_FLEXCUBEXML.Main
Insert
Type:INTEGER:5
Text:CHARACTER:36.4
Insert
Type:INTEGER:5
Text:CHARACTER:SET Environment.Variables.DBResult = THE (SELECT a.cust_ac_no AS :cust_ac_no FROM Database.brsliveread.sttm_cust_account AS a WHERE a.alt_ac_no = ACC);
DatabaseException
File:CHARACTER:F:\build\slot2\S000_P\src\DataFlowEngine\MessageServices\ImbOdbc.cpp
Line:INTEGER:3234
Function:CHARACTER:ImbOdbcConnection::checkRcInner
Type:CHARACTER:
Name:CHARACTER:
Label:CHARACTER:
Catalog:CHARACTER:BIPmsgs
Severity:INTEGER:3
Number:INTEGER:2321
Text:CHARACTER:Root SQL exception
Insert
Type:INTEGER:2
Text:CHARACTER:-1
Insert
Type:INTEGER:14
Text:CHARACTER:odbc32.dll
DatabaseException
File:CHARACTER:F:\build\slot2\S000_P\src\DataFlowEngine\MessageServices\ImbOdbc.cpp
Line:INTEGER:3412
Function:CHARACTER:ImbOdbcConnection::checkRcInner
Type:CHARACTER:
Name:CHARACTER:
Label:CHARACTER:
Catalog:CHARACTER:BIPmsgs
Severity:INTEGER:3
Number:INTEGER:2322
Text:CHARACTER:Child SQL exception
Insert
Type:INTEGER:5
Text:CHARACTER:IM001
Insert
Type:INTEGER:2
Text:CHARACTER:0
Insert
Type:INTEGER:5
Text:CHARACTER:[Microsoft][ODBC Driver Manager] Driver does not support this function |
|
|
Back to top |
|
 |
kimbert |
Posted: Wed Oct 22, 2014 3:33 am Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
Not sure what the problem is, but many other users have reported error code IM001. Use the Search box on this forum to find them - you may find that there is an easy workaround. _________________ Before you criticize someone, walk a mile in their shoes. That way you're a mile away, and you have their shoes too. |
|
Back to top |
|
 |
MB Developer |
Posted: Wed Oct 22, 2014 4:40 am Post subject: |
|
|
 Disciple
Joined: 03 Feb 2014 Posts: 179
|
HI grasher134
Code: |
SET Environment.Variables.DBResult = THE(SELECT a.cust_ac_no FROM Database.brsliveread.sttm_cust_account AS a WHERE a.alt_ac_no = '1234541545154');
|
Once write your statement like below :
SET Environment.Variables.DBResult.Test = THE(SELECT a.cust_ac_no FROM Database.brsliveread.sttm_cust_account AS a WHERE a.alt_ac_no = '1234541545154');
I am not sure it is executed or not but try this...
and also give LocalEnvironment in the place of Environment
 _________________ Thanks....
Last edited by MB Developer on Wed Oct 22, 2014 4:42 am; edited 1 time in total |
|
Back to top |
|
 |
grasher134 |
Posted: Wed Oct 22, 2014 4:40 am Post subject: |
|
|
Acolyte
Joined: 22 Oct 2014 Posts: 62
|
I just gave up.. Made it with PASSTHRU. |
|
Back to top |
|
 |
mgk |
Posted: Wed Oct 22, 2014 7:41 am Post subject: |
|
|
 Padawan
Joined: 31 Jul 2003 Posts: 1642
|
What Database was it (Oracle, DB2)?
Can you post an ODBC trace showing what ESQL passed to the DB?
Thanks. _________________ MGK
The postings I make on this site are my own and don't necessarily represent IBM's positions, strategies or opinions. |
|
Back to top |
|
 |
|