"10," a Blake Edwards comedy that began with George Segal in the lead and ended up with Dudley Moore after a falling-out between the director and Segal, is a sporadically funny, marginally interesting fiasco that might have evolved into a memorable romantic comedy.

Despite its blatant commercial reflexes, evident in the excess falling-in-the-pool, falling-off-a-mountain and peeping-tom gags, "10" is not a typical, formula-ridden piece of material. It's an attempt at a distinctive, classy comedy of manners, as self-consciously theatrical and "sophisticated" in tone as Woody Allen under the influence of Phillip Barry and S. N. Behrman.

If Edwards had lucked out and all the ingredients had jelled, "10" might have been celebrated as the Hollywood equivalent to "Annie Hall" or "Manhattan" -- a kind of "Bel Air" or "Malibu."

The premise is familiar but forever serviceable: a fundamentally privileged man creates trouble for himself by surrendering to middle-aged sexual restlessness and attempting to hog more of the goodies of life than he deserves or needs. Moore plays the character, George, with a rather morose, unappealing self-absorption.

George is the music-composing half of a successful song-writing team; Robert Webber plays the lyricist, Hugh. It is an amusing contrast: runty; pudgy George is a confirmed heterosecual; tall, rugged Hugh is a confirmed homosexual.

George also enjoys the attentions of an articulate, understanding mistress. Called Sam, short for Samantha, this paragon is identified as an operetta star and embodied by Julie Andrews, a sound enough choice in theory but potentially troublesome. Endeavoring to straighten George out, Sam is required to deliver glib, profane dialogue that sounds peculiarly disconcerting coming out of Andrews' mouth and general photogenic essence.

Driving home one afternoon, George glances at a limousine that pulls up beside him and is thunderstruck by the appearance of a young woman in the back seat -- a dazzling beauty dressed in a wedding gown. After some slapstick delaying tactics, George sneaks into the chapel to gaze fondly at this dream girl as she takes her wedding vows. Later, under false pretenses, he learns that the bride is honeymooning at a Mexican coastal resort. Recklessly, George follows her there.

Even during this preliminary phase, Edwards seems to take two dumb steps for every smart one. The prevailing Southern California ambience is very promising: warm and luxurious, a potentially disarming setting for haywire upper middle-class behavior. Wonderful supporting players keep circulating through the action, notably Max Showalter as the minister, a hearty, flannel-mouthed Good Soul who turns out to be an aspiring songwriter and treats us to a perfectly swell composition, a dizzy classic of mixed metaphors called "I've Got an Ear for Love." (His theoretically awful song is actually better than the others Henry Mancini and Robert Wells composed for the film.)

At the same time Edwards can't seem to resist the most miserable sight gags that occur to him -- at the wedding George is bitten on the nose by a bee; at the dentist's he suffers; at home he keeps clunking his head and falling in the pool. Nor can he perceive when he's destroying a truly funny situation with an offensive aside.

It take Edwards much too long to get his protagonist down to the resort. Once there, he miscalculates in a way that decisively degrades the material. After a lame excuse to get the bridegroom out of the way, Edwards allows George to insinuate himself with the dream girl (Bo Derek, John Derek's latest wife, a reincarnation of Ursula Andress) and then discover that she's no better than she should be; in fact, maybe a little worse than she should be.

Of course, the girl's character is beside the point: The crucial issue is bringing George to his senses before he makes an unforgivable fool of himself. George simply has no business butting into the girl's life. By permitting him to do so, and then implying that the girl's character absolves George of guilt, Edwards destroys whatever chance remained of leaving us with a protagonist whose folly merited sympathetic attention.

Ultimately, George is a contemptible character, and that is going to cost "10" at the box-office. Unlike the young hustler played by Charles Grodin in "The Heartbreak Kid," George is not viewed at a satiric distance. Edwards lets him off the hook morally and expects the audience to do likewise. What George requires for eventual audience solicitude is a little strength of character. Curiously, the tool for bringing George to his senses is right at hand: his consoling vocation as a songwriter.

All Edwards needed to do was borrow one of the theme lines from Truffaut's "Shoot the Piano Player": "Music is what we need, man!" Instead, he's allowed a promising script to turn sour and hateful. Despite Edwards' considerable success reviving the Pink Panther farces, "10" seems to be a failed attempt to get something sour out of his system and break into a fresh comic element.