function readOnly(count){ }
Don't have an account?
Search for an answer or ask a question of the zone or Customer Support.
You need to sign in to do that
Sign in to start searching questions
Signup for a Developer Edition
Sign in to start a discussion
List<account> acList=[select id, xyz from account]; if(acList.size()>0) { for(account a: acList){ a.xyz = 'default value'; } } update aclist;
List<account> lstAcc=[select id,Name, xyz__c from account]; list<Account> updatelist = new list<Account>(); for(account acc: lstAcc){ acc.xyz = 'default value'; updatelist.add(acc); } update updatelist ;
trigger ConstantValue on Account (before insert) { String DefaultValue = 'Test Value'; if(Trigger.IsBefore && Tigger.IsInsert){ for(Account Acc:trigger.new){ Acc.xyz__c = DefaultValue; } }
trigger AccountTrigger on Account (before inser) { String valueOfDefault = 'Any Value'; if(Trigger.IsBefore){ if(Tigger.IsInsert){ for(Account A:trigger.new){ A.xyz = valueOfDefault ; } } } }
By using apex you can simply fetch account in query:-
Please mark it as Best Answer if it helps you.
Thanks & Regards
Suraj Tripathi
Try Below Code Please Mark It As Best Answer If It Helps
Thank You!
You Can Try Trigger Or Method In The Image Shown Below Go To Object Manager Select Account Object Select xyz Field To Edit And Do As Shown In Image
Please Mark It As Best Answer If It Helps
Thank You!
One of the ways is to create a trigger on Account:-
Please mark it as Best Answer if it helps you.
Thanks & Regards
Suraj Tripathi