+ Start a Discussion
SachinShethSachinSheth 

Query Mutiple tables using salesforce web service with some condition

Hi
I am using salesforce api for one of my Biz talk integration project .
I want to fire some query with multiple tables say account ,contact etc and with some where condition like urn value null .
Can any one tell me how can i do this as Query method does not support joins .
Please reply as soon as possible if any one knows solution for this
 
Thanks in Advance
Sachin
Gareth DaviesGareth Davies

Sachin,

Can you be more specific about what you are trying to do.

Do you want to populate many object types with the same query condition or do you want to use the result of one query to populate a second (i.e. a join).

Have a look at Datascope (AppExchange) or Explorer (sourceforge) perhaps that will help you test the SOQL possibilities.

Gareth.

SachinShethSachinSheth

Dear Gareth

First of all thanks a lot for your instant reply.

Well i want to populate many object with same query condition say all account details with their opportunities with some where condition like some value =1 or so on.

It is not necessary that i should use query object only any method which gives me relational output will do

Thanks in Advance

Sachin,

 

Gareth DaviesGareth Davies

Sounds like a two-phase query would be the best approach to that.

i.e.

Select all Opportunities where condition is met.

Generate a unique list of AccountID's from Opportunities

Query those for those Accounts using a retreive call

There is no way to perform this as a single operation (that I am aware of).

Cheers

G.

 

SachinShethSachinSheth
Greath
Thanks for your reply.
See my requirement is i want all account details with their address,opportunities in one single result as i need to pass those values to Biz talk.
Solution proposed by you will give me only inner most data.
 
Thanks in Advance
Sachin
qmanqman

If you're using BizTalk, then you already have SQL Server. Using DBAmp , you can excute the SQL statement you need to pull the data (including outer joins).

Let me know if need more info or have any questions.

Bill Emerson

DBAmp Developer

 

SachinShethSachinSheth

Thanks Bill

Yes but this product you are talking is not free product right....

Thanks In Advance

Sachin Sheth

qmanqman

$695 unlimited users.. Got to pay the light bill! :smileyhappy:

Bill

netsmurphnetsmurph
So is there really no other way to perform a very standard database query (ie more than one table) without either paying for this product or writting very bespoke queries???
 
Do salesforce have any plans for introducing the join into their SOQL?
 
 
Andrew
 
 
 
MascotteMascotte
There are no other way to perform what you want.
That's for sure.

I felt the same frustration when I started to use the Sforce API :D
The number of queries becomes rapidely big...

You should better use "retrieve" instead of "query" in certain cases.
"retrieve" gets some objects based on a list of objects ID you have to specify in parameters.

Good luck