Understanding Business Accounts and Person Accounts – Part 2

In Part 1 of this series, we reviewed the difference between a [Business] Account and a Person Account.

Moving from a Business Account to a Person Account is very common and the converse can be as well so how do we make this easy to do?

Let’s review the requirements to create a Person Account from a Contact.

Salesforce states the only path to change a Contact into a Person Account has these requirements:

  1. You must use the Application Programming Interface (API) to do it.
  2. You cannot make any other updates or changes to the record at the same time.
  3. You must create an Account/Contact pair. That’s one Account with one Contact. The new Person Account will take the Account name.
  4. The Account must have a blank Parent Account value.
  5. The Contact must have a blank Reports To value.
  6. All data in any shared fields (i.e. phone, etc.) between the Account/Contact need to match.*

* I have found that converting a Contact with a mailing address and an Account with no address still works with the address being added to the new Person Account.

As I was looking to solve a different problem today, I came across a solution that made this process simple. Instead of using the heavy apps mentioned in my previous post, this one involves adding a simple Custom Link on qualified Business Account Page Layouts that will convert the Account/Contact into a Person Account.

To get this done, follow or print this page for your Salesforce Admin:

  1. While logged into http://www.salesforce.com, click the Setup link at the top of the page, just right of center.
  2. Navigate to Apps Setup > Customize > Accounts > Buttons and Links.
    Navigate to Account Buttons and Links

    Navigate to Account Buttons and Links

  3. Near the bottom of the page, click the New button to the right of the header Custom Buttons and Links.
  4. Use example image below to match your settings exactly.

    Create the Custom Link using Javascript

    Create the Custom Link using Javascript

  5. Paste all of the Javascript code below into the code area and save. Preferably the second one for added safety.
  6. Get the SalesforceID of the Person Account Record Type you would like to convert to.
    1. Navigate to Apps Setup > Customize > Accounts > Person Accounts > Record Types
    2. Copy the value after the “id=” in the URL either by clicking the Record Type name or copying the URL to your clipboard. It usually starts with “012″.
    3. The value I used out of my url is bolded here:
      https://na2.salesforce.com/setup/ui/recordtypefields.jsp?id=0124000000011NS&type=01I400000005qaX&setupid=PersonAccountRecords
  7. Navigate to Apps Setup > Customize > Accounts > Page Layouts
  8. Click the Page Layout you would like to add this Custom Link to. Security note: If you add this to a widely visible Page Layout, you may find that people will convert B2B records because they can. Sigh.
  9. Click Custom Links on the left of the Layout Editor Top Bar.

    Drag your Custom Link onto your Page Layout

    Drag your Custom Link onto your Page Layout

  10. Drag the Custom Link you created onto the Page Layout and save.

    Custom Link is in the Custom Links section in the Page Layout Editor

    Custom Link is in the Custom Links section in the Page Layout Editor

Here is the code courtesy of David Schach of X2OD.com:

{!REQUIRESCRIPT("/soap/ajax/13.0/connection.js")}
var AccountObj = new sforce.SObject("Account");
AccountObj.Id = '{!Account.Id}';
AccountObj.RecordTypeId = '0120000000000000'; // Change by pasting new RecordTypeID
sforce.connection.update([AccountObj]);
location.reload(true);

Changing the red/bold RecordTypeID will change the behavior from a Business Account => Person Account to a Person Account => Business Account. I suppose you could also use this same method to switch Accounts to other Record Types withing B2B and B2C such as a Vendor to a Partner Account, etc.

I like a little confirmation and feedback just to make sure I don’t accidently do this and cause trouble for me (or my client!) so I added a confirm() and alert():

// convert TO a Person Account
{!REQUIRESCRIPT(”/soap/ajax/13.0/connection.js”)}
if(confirm(’Are you sure you want to convert this Account and Contact to a single Person Account (B2C)? This is NOT reversable.’))
{

var AccountObj = new sforce.SObject(”Account”);
AccountObj.Id = ‘{!Account.Id}’;
AccountObj.RecordTypeId = ‘0120000000000000‘; // Paste B2C RecordTypeID
msg = sforce.connection.update([AccountObj]);
alert(msg);
location.reload(true);
}

Custom Link is now visible on specific Page Layout

Custom Link is now visible on specific Page Layout

This will show a little popup confirming what you are doing and that it is not reversable. It is reversable with a little work but I would like others to realize that they should only do this if they know what they are doing. This avoids the accidental curiosity clicks. This also saves the response from Salesforce for a simple alert to confirm all was successful or the error if received. The original behavior just reloads the page with no messaging.

Person Account Created. Success!

Person Account Created. Success!

Thanks again David and I hope this helps many the way it has helped me.

– Jon

Risky Business: Your Aging Computer

I have had my current computer for over 3 years. I had my previous computer for four years before selling it to a college student who still uses it two years later.

Using a computer for six years should be a somewhat rare occurrence but it is not. Data loss is all too frequent and is estimated to cost $2,900 per incident. Ouch! This is foolish when the problem could have been solved for under $300. Even more, hard drives have been failing at an increasing rate as we depend more and more on our computers – sometimes as high as 15% in a single year!

Especially in this economy, fully depreciating (and then some!) our assets is a high priority but so should avoiding a catastrophe.

I encourage this attempt at cost savings as long as you are managing your risk well.

Doing so includes:

  • Automated data backups with multiple versions
    Examples: Mozy for Mac, Carbonite for Windows, Bacula for Linux
  • Routine and scheduled Hard Disk replacements & reuse the old drive
    Example: Within the estimated life of the Hard Drive, often called MTTF, or every three years
  • Contingency planning for downtime
    Example: Have a secondary computer or shared computer just in case. (more…)