Adding Total Invoiced Data To Microsoft Dynamics CRM Account Record

This came up today during our Dynamics SL user group meeting. How can we simply build a marketing list based on total orders? This is a good question as the advanced find is unable to do any math functions. I can pick a specific set of customers based on what specifically they have ordered, but if I want to group or sort customers based on the total amount invoiced, that is going to be a problem.  

A simple workflow and a single custom field can do the trick. Mitch Milam addressed this issue on the CRM team blog a year ago. Here is excerpts from the article that can be read at

http://community.dynamics.com/blogs/crmmitchmilam/comments/10601.aspx

 —————————————————————————————————————————————————————

 If you haven't spent much time reviewing CRM 4.0 workflows, you should.  You can perform some amazing things without ever writing code. Let's perform the exact same steps using CRM 4.0 workflow.

First, we create a workflow based on the Invoice Entity that has the following properties:

Step 1:  Create a Check Condition using the following information:

Step 2:   Add and Update Record step, on the Related Entity Customer (Account):

image

Step 3:  Click the Set Properties button, then set the Total Invoiced Attribute to the following:

Note: Total Invoiced is a custom Money Field.

By using the Increment by Operator, we are able to increment any existing Total Invoiced amount by the amount found in the Invoice's Total Amount field.

Final Step:

Save and Publish this workflow.

Conclusion:

So, is there a difference between these techniques? Not really. Both accomplish the job in a very similar manner but the Workflow solution requires zero code maintenance and a normal user or administrator can create the workflow.

The biggest difference between the two techniques is in the timing of the actual update. Plugins can be executed either Synchronously or Asynchronously.  Workflows function in an asynchronous manner.

The Synchronous operation will modify the data stream as it is being saved to the database, which can introduce a delay in the user's experience, but will provide results back to the user in a quicker fashion.

Asynchronous operations will happen shortly after the data has been saved which will not impact the user, but which may result in a slight delay between the time the user saved the record and when the value will be updated.

If you can live with the time delay, I feel that workflow is the way to go, in most cases.  If you can't, then download the SDK and start working through their examples.

 
Trackbacks
  • No trackbacks exist for this entry.
Comments

  • November 17, 2009 Data Security wrote:
    Thanks! This looks really useful; I've added it to my favorites.
    Reply to this
    1. June 29, 2010 baseball jersey wrote:
      I've added it to my favorites.
      Reply to this
  • December 3, 2009 Data Security Tools wrote:
    Thanks for help....
    Reply to this
  • February 16, 2010 Christine wrote:
    beef recipes.

    mac data recovery.
    Reply to this
  • March 15, 2010 PCSecurityShield.com wrote:
    Great blog....
    Reply to this
  • May 6, 2010 Mothers day SMS wrote:
    Thanks for your support and informative post.
    Reply to this
  • May 7, 2010 penetration testing wrote:
    Thanks for posting this information, and the illustrations. In terms of synchronous vs. asynchonous, what is the difference in security - has penetration testing taken place with these operations?
    Reply to this
  • May 14, 2010 Online Employee Scheduler wrote:
    Thanks for the information the CRM is really great for me to store all the business information....
    Reply to this
  • May 18, 2010 migliore sito di Roulette wrote:
    Is there anything happening around Connectors (the old protocol handlers)? We're keen to get the FAST 2010 RC hooked in with CRM, SharePoint (2007 & 2010), Hummingbird DM 5 and a DB/filesystem based email archive.
    Reply to this
  • May 21, 2010 sf wrote:
    Aww, this was a really quality post. In theory I’d like to write like this too – taking time and real effort to make a good article… but what can I say… I procrastinate alot and never seem to get something done.
    Reply to this
  • May 21, 2010 louboutin wrote:
    Good read. There is currently quite a lot of information around this subject on the net and some are most defintely better than others. You have caught the detail here just right which makes for a refreshing change – thanks.
    Reply to this
  • May 25, 2010 internet marketing agency wrote:
    This is really amazing tool man....
    Reply to this
  • June 9, 2010 annuaire casino wrote:
    Thank you for the work you have put into this post, it helps clear up some questions I had.I will bookmark your blog because your posts are very informative.We appreciate your posts and look forward to coming back...
    Reply to this
  • June 21, 2010 Akhbar-e-Jehan wrote:
    Wonderful post... Very informational and educational as usual!
    Reply to this
  • July 1, 2010 Shane Garcia wrote:
    It is really very easy to manage all customers records and data and this sorting with different parameters is really going to help. I am also waiting for newer version which should have some other features.
    Reply to this
  • July 3, 2010 Watch Full Movies Online wrote:
    Thats amazaing
    Reply to this
  • July 5, 2010 Bvlgari jewelry wrote:
    thank you
    Reply to this
  • July 5, 2010 Bvlgari jewelry wrote:
    thats amazaing
    Reply to this
  • July 5, 2010 Ramadan SMS wrote:
    Wonderful post... Very informational and educational as usual!
    Reply to this
  • July 20, 2010 Singles Auckland wrote:
    thank you
    Reply to this
Leave a comment

 Enter the above security code (required)

 Name (required)

 Email (will not be published) (required)

Your comment is 0 characters limited to 3000 characters.