You need to sign in to do that
Don't have an account?
lopezc
Can I create a a new lookup field into the Task Object?
hi All,
I will like to create a new lookup field in the task Object. I know that for creating new custom fields I have to go to Activities custom fields in the menu bar. However, I don't have the option to create a lookup field.
My problem is that I would like to add to the task views a new field (Account Number) from the Lead/Contact related to the task. I don't know a priori if the task will be related to a Lead or Contact.
Any Ideas?
Many Thanks!
I will like to create a new lookup field in the task Object. I know that for creating new custom fields I have to go to Activities custom fields in the menu bar. However, I don't have the option to create a lookup field.
My problem is that I would like to add to the task views a new field (Account Number) from the Lead/Contact related to the task. I don't know a priori if the task will be related to a Lead or Contact.
Any Ideas?
Many Thanks!
I created a triggered on Task, but this is giving me an error:
caused by: System.Exception: Too many SOQL queries: 21
Trigger.TaskAccountNumber: line 28, column 33
The problem is that I don't know a priori if the task is related to a Lead or a Contact. Here is my code:
Do you know what I am doing wrong? There is no another way? I have a few triggers on Contacts already and I know that the number of Queries is limited..
Thanks for your help!
The Too Many SOQL queries might be a red herring – it seems like you're only doing 2 in there, but your other triggers may be doing the other 19.
http://www.salesforce.com/us/developer/docs/apexcode/Content/langCon_apex_loops_for_SOQL.htm
It would involve more logic in your if statements instead of the WHERE clause but might help you avoid running into the limit.