I love a good wedding, and 2006 was full of some winners.

Tom Cruise and Katie Holmes. Nicole Kidman and Keith Urban. Pamela Anderson and Kid Rock.

Lots of corporate weddings, too, in 2006. Phelps Dodge ( PD) said it would buy two major Canadian nickel miners, Inco and Falconbridge, in a $40 billion transaction that would create the largest mining company in North America. (That's the largest announced mining deal on record, according to deal tracker Dealogic.)

AT&T ( T) agreed to buy BellSouth for a mere $66.7 billion. And although the deal was not nearly as expensive, Google's ( GOOG) $1.65 billion offer to buy YouTube was still a jaw-dropper.

Globally, there were $3.79 trillion worth of deals last year, up 38% from 2005, according to Thomson Financial. But can it continue?

Seems so.

Just this past week alone, US Airways ( LCC) jacked up its hostile bid for Delta to about $10 billion. And earlier this month, General Electric ( GE) said it will buy Smiths Group, the U.K.'s third-largest aerospace company, for $4.8 billion.

But from the shareholder's point of view, merger and acquisition activity can be confusing. Last week Booyah Breakdown touched on these complications in a reader's M&A question. But you wanted more! Your questions poured in. So let's tackle what happens when you're a guest at one of these corporate weddings.

Do You Even Want to Be Invited?

To start, a merger happens when two companies of equal stature come together to create one large company. These days, that's pretty rare. In most instances, a larger company acquires a smaller one. So when the press says your company is "merging" with another one, you can bet that there's a big company buying a little company, and the little company will soon disappear.

Still, the minute you hear your company is "merging" with another or being acquired, decide if you even want to be a part of the marriage.

Let's face it, not all marriages are good ones, no matter if it's consummated in Hollywood or Wall Street. Pam Anderson and Kid Rock called is splitsville after only four months. And mention the AOL- Time Warner ( TWX) deal on Wall Street and see who throws up first.

Things just don't always work out the way the people expect.

So it's up to you to do some due diligence on the deal. Pull up the annual report of the company that's looking to combine with yours. Read the opening text in the front of the report, and you'll be able to get a feel for the company. The letter from the president and management's discussion and analysis will tell you where the company sees itself. Check if there are synergies in the product lines as well as the internal cultures. Then decide if you see yourself with them.

If you decide this union is headed for divorce court, then drop the stock before the actual merger date. But if you want to go along for the ride, make sure you understand the transaction.

The Straightforward Deals

In any deal you need to know what you're getting and whether the deal is taxable to you.

If your company is being acquired, you will most likely lose your shares and receive either cash for your shares, new shares of the big company coming in or a combination of both.

With a cash purchase, the buyer just gives cash, and you're done with the investment. So take your money and run. With a stock deal, you'll render your old shares and get new shares in the bigger company. This is where things get hairy, because you'll probably have to recalculate the basis for your new shares. That's accounting-speak for spreading the original cost of your shares of the little company over the new shares you got from the deal.

Let's presume you spent $100 for your four shares of the stock that was just acquired. You paid $25 per share. So $25 is your basis in each share. As part of the deal, you got two shares of the purchasing company for every single little share you had. So instead of four little company shares, you now have eight big-company shares. Since you originally spent $100 to get those four shares, you have to spread that original $100 over your new shares. So your new basis in each of those new shares is $12.50 ($100 divided by eight).

Next, is it taxable?

If the deal is taxable, you'll owe capital gains taxes on the fair market value of the new shares you get, minus your basis. So in our example, you'll owe tax on the difference between the current share price and your basis of $12.50.

If the deal is tax-free, you'll still have to readjust your basis, but you won't have a tax bill until you sell those new shares. That's why a tax-free deal is much better for investors -- it allows them more control over their tax situation. Another tax-free perk is that your holding period is carried over. So if you bought your original shares two years ago, it will be assumed that you've been holding the new shares for two years as well.

The Not-So-Straightforward Deals

But not all deals are that simple. Take the Host Hotels ( HST) deal. In April 2006, Host Hotels, then known as Host Marriott, paid $4 billion to buy 38 luxury and upscale hotels from Starwood Hotels and Resorts Worldwide ( HOT).

The problem is that some of the Starwood shares were considered "special" and represented two separate securities, according to Stevie D. Conlon, senior tax analyst for CCH Capital Changes, a company that provides coverage of corporate actions affecting publicly traded companies

Dubbed the HOT shares, each of these special HOT shares represented a piece of Starwood Worldwide and a piece of the company's REIT. So you actually got two things for the price of one. The problem was that Host Hotels bought only the REIT portion of that share. So shareholders now have to separate their basis in that HOT share between the Starwood Worldwide piece and the REIT. Holy tedious. Oh, and shareholders will have to recalculate their basis by April 16, 2007, because the transaction will need to be reported on their 2006 tax return.

And the kicker: The deal is fully taxable to shareholders. Ugly.

But it gets worse. Alberto-Culver ( ACV), the company that makes Alberto V05 shampoo, wanted to separate its consumer products business and its retail business into two separate publicly traded companies through a tax-free transaction, according to Conlon. And as part of this complicated transaction, it decided to pay each shareholder a whopping $25 dividend. Very cool, right?

Not so much. Thanks to onerous tax rules, no one knows how to tax this distribution. Is it ordinary income taxed at your regular tax rate? Or is it a capital gain distribution, subject to the lower 15% rate? Who knows? And no one will know until 2008. That's right, 2008 -- when the company finalizes its 2007 year-end numbers.

So for now, shareholders have to report the whole dividend as ordinary income on their 2006 tax returns, says Conlon. But odds are very good that they will all have to amend those returns in 2008 when the company finally figures out how much of that dividend will be taxed at the capital-gains rate.

I'm not kidding. This stuff is nuts.

Call the Wedding Singer

So how do you figure all this out? Well, you can read the proxy statement. It will help you figure out your basis in your shares, although I think it would be easier to read Leo Tolstoy's War and Peace in Russian.

You could call your broker or the company's investor relations department and try to have them help you. Or you can get your trades in a program that will recalculate your basis for you. I've said this before, but I think GainsKeeper is the way to go. Just download your trades from your broker, and it will take care of all this minutiae for you, says Chuck Ross, GainsKeeper's general manger. That includes spinoffs, reinvested dividends and other complicated basis calculations.

For $59 a year, you can input 150 trades, and for $159 you've got up to 1,000 trades. Or you can go with the unlimited trading for $659, starting Jan. 29, 2007, according to Ross.

So enjoy the wedding circuit down on Wall Street. The guests are always dressed to impress. Just make sure you understand the many nuances of these marriages.

Tracy Byrnes is an award-winning writer specializing in tax and accounting issues. As a freelancer, she has written columns for wsj.com and the New York Post and her work has appeared in SmartMoney and on CBS MarketWatch. Prior to freelancing, she spent four years as a senior writer for TheStreet.com. Before that, she was an accountant with Ernst & Young. She has a B.A. in English and economics from Lehigh University and an M.B.A. in accounting from Rutgers University. Byrnes appreciates your feedback; click here to send her an email.

More from Personal Finance

'Worn-out' Shoemakers Still Have a Chance to Heal

'Worn-out' Shoemakers Still Have a Chance to Heal

Summer Travel: The Best Places to Visit in the U.S.

Summer Travel: The Best Places to Visit in the U.S.

9 Best Investment Books for Beginners

9 Best Investment Books for Beginners

How to Calculate Your Net Worth and Pin Down Your Financial Health

How to Calculate Your Net Worth and Pin Down Your Financial Health

The Best States for Millennials' Money and Health

The Best States for Millennials' Money and Health