The phrase like a dog with two tails means extremely pleased, delighted.
Of American-English origin, it alludes to the belief that a dog wags its tail as a sign of pleasure or happiness.
The earliest occurrence that I have found is from a letter from Zebulan Harrowtooth, in Boston, to his uncle, Jonathan Hoehandle, in Vermont, published in the Western Herald & Steubenville Gazette (Steubenville, Ohio) of Saturday 5th January 1822:
I suppose you remember Sam Sharpshins, who was whipped at the academy in Floggemwell, two or three years ago, for stealing pigs out of ’Squire Pinchbelly’s pen. He is a great merchant here now, and swaggers like a dog with two tails.
The second-earliest occurrence that I have found is from The Dreamer—No. V., a text by ‘Simon Snorer Esq.’ about two opposing political factions, published in the Edwardsville Spectator (Edwardsville, Illinois) of Saturday 21st January 1826:
“They’re nothing but a set of shiftless, good-for-nothing critters that han’t got edecation enough to know a figure 4 from a pig-yoke. I vam [=?] I’d like to see haow some on ’em u’d make out at writing resolutions and drafting bills at the legislater—but if they do get ahead on us, they’ll be as proud as a dog with two tails.”
The phrase occurs, again as as proud as a dog with two tails, in Three years in Canada: An account of the actual state of the country in 1826-7-8. Comprehending its resources, productions, improvements, and capabilities; and including sketches of the state of society, advice to emigrants, &c. (London: Henry Colburn, 1829), by the Scottish engineer and poet John Mactaggart (1791-1830):
Off went the Laird, as proud as a dog with two tails.
A variant of the phrase occurs in a letter from Major Jack Downing 1, in Concord, New Hampshire, to his uncle, Joshua Downing, in Downingville, published in the Norfolk Advertiser (Dedham, Massachusetts) of Saturday 20th July 1833:
The President pricked up his ears and looked as tickled as a dog with two tails.
1 Major Jack Downing is a fictional character created by the American author and humorist Seba Smith (1792-1868).
Yet another variant of the phrase occurs in a letter to Major Jack Downing, published in the Maine Working Men’s Advocate (Belfast, Maine) of Wednesday 4th September 1833; the author, who signed themself Ike Downing, described a picture of Jack Downing:
Staring at me, there was you, Jack, body and soul, as natrel as if you was alive—carrot locks, rolled up like an asses tail, striped jacket, and looking most tarnal 2 cute and knowin, and as grand as a dog with two tails.
2 The adjective tarnal, representing a regional pronunciation of eternal, is an intensive.
This paragraph was published in the Connecticut Herald (New Haven, Connecticut) of Tuesday 25th February 1834:
New-Haven, Feb. 19, 1834.
Pig or Puppy.—Our Register neighbor is quite in a quandary about the deposites [sic] and the U.S. Bank. He is not “exactly” in favor of the measures adopted by the government,—and he is not in favor of the measures adopted by the people to obtain relief; yet he alternatively sides with both, and comes out “pig or puppy” at discretion. His vision seems to be obstructed by the prospects of the next State Election, upon which all his hopes depend of assuming a real and substantial character as a politician. All things are liable to change, but there is sometimes a difficulty in the operation, especially when it is too frequent and rapid, which hardly gives time to observers to discover the identity of the subject. To day the Register comes out, bow-wow-wow, as if we should be able to discover whose dog he is;—to-morrow runs back again, queak, queak, queak, to his pen, curls up his tail, and grunts about “Old Federalism.” After some “agonizing spasms,” he ventures forth again, but some horrid phantom soon crosses his path, and he retreats again, to take a new start in the old career of “this side up.” We hope he will shortly find a “starting point” to lead him to the goal of his idolatry, when he can come out “orthodox” and pure, bright as a chameleon, and tickled as a dog with two tails.
In the following from All Sorts of Paragraphs, published in the Boston Morning Post (Boston, Massachusetts) of Saturday 24th July 1841, as a dog with two tails connotes bizarreness, not pleasure:
Mr Greene 3.—Please to ask your Buffalo correspondent, what the mizen-mast of a schooner is. The lake schooners may have mizen-masts, but our salt water schooners would feel as strange with one, as a dog with two tails.
☞ Will the writer of the above please to inform us by what name he would designate the after mast of a three-masted schooner?
“Truth is a spark to which objections are like bellows.”
3 The American journalist Charles Gordon Greene (1804-86) was co-founder and editor of the Boston Post.