The story of "The Unexpected Inheritance" is a saucy little tale about promiscuity and its rewards - or its punishments, depending on how you look at it.

I first heard it in 1982 from an Irish folklorist with a long, difficult name that I was never able to pronounce properly (her name also has too many odd accents to be printed in an American newspaper). She published it under the title "The Kilkenny Widow":"Two men, John and Mick, went to Kilkenny for the day. In the evening they decided they would put off the journey back to Dublin till the following day and stay the night in a pleasant hotel there, which was owned by an attractive widow whom they were getting to know.

"After spending an enjoyable evening in the bar, they made their way to their separate rooms. When all was quiet, though, Mick tiptoed off to the widow's room and spent the rest of the night with her. He returned to his own room in the early morning.

"When the two men were leaving later that day, the widow called Mick aside and said, `I have your two names in the register, but I just want to be sure who's who.'

"So Mick, a quick thinker, gave John's name and address instead of his own, and the widow wrote it down.

"Mick had forgotten all about his adventure in Kilkenny until months later, when he had a telephone call from John, who was highly excited."

What John said to him was this: "Listen, Mick, do you remember that outing we had in Kilkenny? Well, I've just had a letter from a solicitor there, and he says that nice widow who ran the hotel we stayed in has died, and in her will she left me the hotel and a lot of money. I just don't understand it!"

The story sounds like one that might have been written by Boccaccio, or maybe by Chaucer in his racier moments, yet it does not occur, to my knowledge, in these or other likely literary sources.

The Irish folklorist had heard the story in 1980 from a lecturer at University College Dublin. He in turn had heard it from his wife, who said the story had been "going the rounds" the previous year and was supposed to be true.

Three years after I heard the Irish version of "The Unexpected Inheritance," however, I came across an Italian parallel - which, ironically, was recounted by a distinguished Irish novelist.

The Italian version appeared in The New York Times on Sept. 26, 1985, in a column entitled "Hers," by Edna O'Brien.

The subject that day was "perils and joys of promiscuity," and to illustrate her theme O'Brien summarized this "chastening story," which she said she had heard recently in Rome:

"A Mr. X met a Mrs. Y on a sleeper train and spent some happy hours with her. For fear of discovery Mrs. Y had given the name and address of Mrs. Z, a woman she slightly knew. A few years later when Mr. X died, a large sum arrived for Mrs. Z, thanking her for an unforgettable night."

All that X, Y, Z stuff blunts the effect of the story, I think. But there's no doubt that we are dealing with the same unexpected inheritance story. Mr. X is just "The Kilkenny Widow," turned into a male Roman seducer and spending a night on a train instead of at a country inn.

-Jan Harold Brunvand is the author of "The Choking Doberman," a collection of urban folklore. Send your questions and urban legends to Prof. Brunvand in care of this newspaper.