You need to sign in to do that
Don't have an account?
How to Query audit fields in SOQL query?
Hi,
i have created a custom object say 'test__c' and i writing a query to get the 'created date field'.
But m getting the error as
"select CreatedBy from test__c
ERROR at Row:1:Column:8
No such column 'CreatedBy' on entity 'test__c'. 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."
I want to do delete opertaion based upon time given in createdBy field.
Cant we include audit fields in SOQL query?
ALso i cant see 'Created Date' field in my custom object.
Any Help..!
Thanks..!
Hello,
There is no standard field with the name CreatedBy, that is why you are getting this error. Try this:
SELECT CreatedById,CreatedDate FROM test__c