
SELECT Id, Subject FROM Task
However, if I remove the Related To field, the task does not show up in the query results - the task still exists in salesforce.com though.
Why is the task not returned, and what query should I use to find it?
2 respuestas
The query is fine, the record will be there I suggest you add an ORDER BY CreatedDate DESC to put the latest tasks at the top. RelatedTo has no effect on the query.
This query is likely to blow up though if you don't add a WHERE clause.