3 件の回答
Hiii AndegosuYou can also use after trigger.to getting the data about 16000 Postal code we should go for the batch class which help us to get records easily.and According to me map will help full for usbecause of below line"***.get(c.PostalCode)" will return name of association according to postal code.As i say above to get the data about postal we use batch apex class and a method which return data of postal codes.And i have another method which also help full for you
trigger ContactBI on Contact(before insert){
String str;
for(Contact c:trigger.new){
str=c.PostalCode;
}
Association as=[select id,name,PostalCode from Association where PostalCode=:str limit 1];
for(Contact c:trigger.new){
str=ac.Name;
}
}
I think this code is help for you
and my this code is not exact as you think this is only demo