January 2012 Entries

Creating a custom BizTalk 2010 pipeline component–Part 3

I hadn’t intended for there to actually be a part 3 to this series, but I realized that I failed to talk about how to get the xml back into the message once you’re done messing with it. You have to convert it to a MemoryStream and assign it to IBaseMessage.BodyPart.Data, like this: public Microsoft.BizTalk.Message.I... Execute(Microsoft.BizTalk.C... pc, Microsoft.BizTalk.Message.I... inmsg) { IBaseMessagePart bodyPart = inmsg.BodyPart; ......

Creating a custom BizTalk 2010 pipeline component–Part 2

In the last post I showed how to create the skeleton of a pipeline components, add it to the toolbox, integrate it into a BizTalk app and deploy & test it. This time I’ll go over working with the XML, reading and writing message context properties, and reading and writing custom component properties. To get the xml portion of the message, you can get a Stream from IBaseMessage.Body.Part.GetO... and load it into an XmlDocument. In our case we’re manipulating the structure of an ......

Creating a custom BizTalk 2010 pipeline component–Part I

Recently at work we had a need to be able to manipulate the XML version of a HIPAA EDI file before it hit any of our BizTalk orchestrations, so I decided to do this with a custom pipeline component. There are other (possibly better…) ways of doing this, but sometimes you just have to work with what you’ve got. I can never remember all the little bits and pieces you have to set up in a custom pipeline component, so I decided to give the BizTalk Server Pipeline Component Wizard a try. The wizard walks ......

Validating NPI (National Provider Identifier) numbers in SQL

If you work with any kind of healthcare data, then odds are you’ll deal with NPI (National Provider Identifier) numbers. The NPI is a 10-digit number consisting of 9 digits (with the first digit being a 1 or a 2) followed by a check digit. The check digit uses the Luhn algorithm, which is calculated like this: Double the value of alternate digits beginning with the rightmost digit. Add the individual digits of the products resulting from step 1 to the unaffected digits from the original number. Subtract ......

Book Review: MAKE Ultimate Kit Guide 2012; O’Reilly Media

If you're interested in hacking (and by that I don't mean programming, I mean cobbling together various wires, circuits, bits and gizmos to form something new and innovative) then you've probably come across MAKE magazine. The folks at MAKE have released a special edition: MAKE Ultimate Kit Guide 2012. At 101 square-bound pages, and a $9.99 price tag, it's something more than a magazine but not quite a book. The first 30 pages are devoted to the kit "industry" itself, with articles on: The Rally ......