function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
frankcsefrankcse 

Nested Queries

Hi
Can any one help me for this?
 
Citys= sforce.connection.query('Select name,id from City__c where StateIdlk__c= '"+ vStateId.options(vStateId.selectedIndex).value +"' and (name not in(select CityId__c from CountryDetails__c))", null);
 

In this select query i am using two objects ...
Dos Salesforce allow me to have two object?...
 
In My application it throws an error like this
 
{faultcode:'sf:MALFORMED_QUERY', faultstring:'MALFORMED_QUERY: StateIdlk__c='a0050000007uMhzAAE' and a.name!=b.cityId__c ^ERROR at Row:1:Column:119unexpected token: b.cityId__c', detail:{fault:{exceptionCode:'MALFORMED_QUERY', exceptionMessage:' StateIdlk__c='a0050000007uMhzAAE' and a.name!=b.cityId__c ^ERROR at Row:1:Column:119unexpected token: b.cityId__c', row:'1', column:'119', }, }, }
undefined
 
Thanks
Regards
Franklin