ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » doubt on select query

Post new topic  Reply to topic
 doubt on select query « View previous topic :: View next topic » 
Author Message
veera_satya
PostPosted: Wed Jun 16, 2010 5:47 pm    Post subject: doubt on select query Reply with quote

Newbie

Joined: 16 Jun 2010
Posts: 3

HI All,

I need a small favour in esql coding.

I have a scenario to get the entire row from Environment selectively and store in a local varibale. I need to use this variable till this esql only for validation.

for example:
Set localVar[] = select * from Environment.Data.SCF_TABLE[] as S1
where S1.Feild1='CBS';

Can i use this as it is? or need to do any modification. Could you please suggest me.

Thanks,
Veera
Back to top
View user's profile Send private message
veera_satya
PostPosted: Wed Jun 16, 2010 6:22 pm    Post subject: Reply with quote

Newbie

Joined: 16 Jun 2010
Posts: 3

Any suggessions please. I am able to retrieve single value from entire row.
Set localVar = select ITEM S1.SCFCODE from Environment.Data.SCF_TABLE[] as S1
where S1.Feild1='CBS';

Because this is single value. But i am not able to proceed with the below requirement. Any body can suggest me please.

Thanks,
veera
Back to top
View user's profile Send private message
veera_satya
PostPosted: Wed Jun 16, 2010 7:58 pm    Post subject: Reply with quote

Newbie

Joined: 16 Jun 2010
Posts: 3

for single value:

It is working for getting single value
Set localVar = THE(select ITEM S1.SCFCODE from Environment.Data.SCF_TABLE[] as S1
where S1.Feild1='CBS');

For retrieving whole row:

This is not working
Set envRef.Data.Temp[] = select * from Environment.Data.SCF_TABLE[] as S1
where S1.Feild1='CBS';


Could you please suggest me how to proceed for getting whole row.
Back to top
View user's profile Send private message
kimbert
PostPosted: Wed Jun 16, 2010 11:57 pm    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Quote:
I need to use this variable till this esql only for validation.
Please describe this 'validation'?

Quote:
This is not working
Those words should be banned on this forum. Please describe the problem properly, or else don't mention it at all.

Quote:
Could you please suggest me how to proceed for getting whole row
What do you mean by 'whole row'?
Back to top
View user's profile Send private message
mqjeff
PostPosted: Thu Jun 17, 2010 2:20 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

One of your two ESQL Select statements is proper ESQL syntax.

One of them is not.
Back to top
View user's profile Send private message
sushilishere
PostPosted: Sun Jun 20, 2010 11:06 pm    Post subject: Reply with quote

Apprentice

Joined: 27 Jul 2008
Posts: 36

Is it throwing an exception or is it not selecting any values!!

Kindly elaborate!!

The select statement over any Row type variable is valid.

Suggestion : Do not use * . Specify all the column names. ( kinda followed as best practice in my place )
Example :
SET Environment.Variable.SelectAttack[] = Select
InputRoot.MRM.localElement2.localElement1
from InputRoot.MRM.localElement2[] AS IES where InputRoot.MRM.localElement2.localElement.localElement1='100';



This was
_________________
----------------------------
IBM MQ v6.0 Sys Admin
IBM MBv6.0 Sol Desgnr
----------------------------------------------------
By the Mountain Side.. looking at the Great Divide
----------------------------------------------------
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » doubt on select query
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.