+ Start a Discussion
Surender reddy SalukutiSurender reddy Salukuti 

query problem

when i wrote query in query editor.

select id from user where profile='system administator'
[object Object]: select id from user where profile='system administator' ^ ERROR at Row:1:Column:27 No such column 'profile' on entity 'User'. If you are attempting to use a custom field, be sure to append the '__c' after the custom field name. Please reference your WSDL or the describe call for the appropriate names.

below question

fetch all the account Records from Account  which are owned by the user whose profile is System Admin and re-assign to User whose profile is manager how can i achive

vinod ram 9vinod ram 9
Hi Surender,

Please try below Query,

Select id,name,profile.name from user where profile.name ='System administrator'

Raj VakatiRaj Vakati
Use this SOQL 

select id from user where Profile.Name='system administator'


select id from Account where Owner.Profile.Name='system administator'

Naveen PoojaryNaveen Poojary
Hi Surender,
System administrator profile API is name Admin. use the API name instead of.System administrator.
Make it as best answer if it helps you