Author |
Message
|
Seb |
Posted: Tue Jun 02, 2009 12:32 am Post subject: Problem with CONTAINS function |
|
|
Apprentice
Joined: 27 Mar 2009 Posts: 41
|
Hi all,
what's wrong with this code:
Code: |
SET IsExcepElem = CONTAINS( FIELDNAME(ExcepListRef), 'Exception'); |
Error Output:
Incorrect function or procedure name "CONTAINS" or argument count.
Thanks in advance for all hints!
Cheers,
Seb |
|
Back to top |
|
 |
AkankshA |
Posted: Tue Jun 02, 2009 12:45 am Post subject: |
|
|
 Grand Master
Joined: 12 Jan 2006 Posts: 1494 Location: Singapore
|
CONTAINS operator :O .... well my WMB help contents does not show me any operator as CONTAINS...
what exactly are you trying/intend to achieve here ?? _________________ Cheers |
|
Back to top |
|
 |
Seb |
Posted: Tue Jun 02, 2009 12:56 am Post subject: |
|
|
Apprentice
Joined: 27 Mar 2009 Posts: 41
|
Hi,
actually the InfoCenter tells me:
Code: |
>>-CONTAINS--(--SourceExpression--,--SearchExpression--)------->< |
I want to test if the field name of my reference contains the word "Exception". Thus, the number and also the types of the arguments should be correct in my case. |
|
Back to top |
|
 |
flahunter |
Posted: Tue Jun 02, 2009 1:02 am Post subject: |
|
|
 Acolyte
Joined: 30 Oct 2008 Posts: 62
|
Actually, it's a new function in V6.1 not in V6.0 or V5.0 |
|
Back to top |
|
 |
Seb |
Posted: Tue Jun 02, 2009 1:05 am Post subject: |
|
|
Apprentice
Joined: 27 Mar 2009 Posts: 41
|
That's what I have ... 6.1.0.3 + iFix 003 for the WMBT  |
|
Back to top |
|
 |
Vitor |
Posted: Tue Jun 02, 2009 1:10 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
Seb wrote: |
That's what I have ... 6.1.0.3 + iFix 003 for the WMBT  |
I have a faint memory of this being asked before, and the advice being raise a PMR. Certainly doesn't work in my copy of v6.1 either.
Until there's a response to the PMR (or a better reply to your post!), use POSITION instead.  _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
AkankshA |
Posted: Tue Jun 02, 2009 1:11 am Post subject: |
|
|
 Grand Master
Joined: 12 Jan 2006 Posts: 1494 Location: Singapore
|
oops.... 4give my ignorance...
anyways... did u try storing source and search expression in variables of charater type and then comparing ??? _________________ Cheers |
|
Back to top |
|
 |
Seb |
Posted: Tue Jun 02, 2009 1:21 am Post subject: |
|
|
Apprentice
Joined: 27 Mar 2009 Posts: 41
|
@Vitor: Thanks for your advise.
@AkankshA: Neither works. Indeed, it seems to be a bug in the CONTAINS implementation. |
|
Back to top |
|
 |
mgk |
Posted: Tue Jun 02, 2009 4:18 am Post subject: |
|
|
 Padawan
Joined: 31 Jul 2003 Posts: 1642
|
You did not post the whole error message, so I can't tell if it is from the Toolkit or from the Runtime (after a deploy). Can you post the whole message please. If it is after deploy, are you sure your runtime broker is 6.1.0.3 and not an earlier version?
Regards, _________________ 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 |
|
 |
Vitor |
Posted: Tue Jun 02, 2009 4:21 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
mgk wrote: |
You did not post the whole error message, so I can't tell if it is from the Toolkit or from the Runtime (after a deploy). |
FWIW I get the error from the Toolkit:
Code: |
Build id: 6.1.0.3-IFix003-20090305_1223
|
_________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
mgk |
Posted: Tue Jun 02, 2009 4:25 am Post subject: |
|
|
 Padawan
Joined: 31 Jul 2003 Posts: 1642
|
If it is a toolkit error, then you can raise a PMR to get a fix for the ESQL syntax checker in the toolkit. Whilst you are waiting, you could try to use an "executable comment" to bypass the checker and send to code to the runtime where it should be processed as you expect. For example:
Code: |
/*!{ SET IsExcepElem = CONTAINS( FIELDNAME(ExcepListRef), 'Exception'); }!*/ |
Regards, _________________ 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 |
|
 |
Seb |
Posted: Tue Jun 02, 2009 4:48 am Post subject: |
|
|
Apprentice
Joined: 27 Mar 2009 Posts: 41
|
Ok, when I use the executable comment, I get a deployment error:
BIP2558E: Undefined function '.CONTAINS'
As far as I know the Broker is on patch level 6.1.0.3. |
|
Back to top |
|
 |
mgk |
Posted: Tue Jun 02, 2009 5:07 am Post subject: |
|
|
 Padawan
Joined: 31 Jul 2003 Posts: 1642
|
Hello. This error almost certainly implies that you are deploying to an older (pre-6.1.0.3) broker. Can you run "mqsiservice -v" on the machine you are deploying to and look at the version deployed on that box.
Kind Regards, _________________ 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 |
|
 |
mqjeff |
Posted: Tue Jun 02, 2009 5:09 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
mgk wrote: |
Hello. This error almost certainly implies that you are deploying to an older (pre-6.1.0.3) broker. Can you run "mqsiservice -v" on the machine you are deploying to and look at the version deployed on that box. |
Is this one of those hidden things that one has to use mqsichangebroker -f with? |
|
Back to top |
|
 |
Seb |
Posted: Tue Jun 02, 2009 5:19 am Post subject: |
|
|
Apprentice
Joined: 27 Mar 2009 Posts: 41
|
Ok...
1st call simply asking for the version- admins answer: 6.1.0.3
2nd call asking to run mqsiservice - admins answer 6.1.0.2 *ups*
Their development environment is running on WinServer 2000 and it seems 6.1.0.3 needs WinServer 2003
Should I open a PMR or is it already work in progress? We cannot use CONTAINS anyway. |
|
Back to top |
|
 |
|