The Maryland Democratic Party's annual dinner traditionally is a time for candidates and stalwarts to set aside their differences and unite behind the goal of electing Democrats to state and national offices.

The 1986 dinner -- held tonight at a suburban Baltimore catering hall as the party looks ahead to some of the most competitive and bitter primary campaigns in many years -- was different, however.

The table talk tonight was not of common victory in November and at the national level in 1988, but of what many said was a decidedly unharmonious snub of the dinner by Baltimore mayor and gubernatorial candidate William D. Schaefer.

Schaefer, who holds a commanding lead over his Democratic rival, state Attorney General Stephen H. Sachs, not only chose to pass up the annual fund-raiser to attend a concert, but also did it on a day when he found time to attend an afternoon fund-raiser for a Republican congresswoman.

Schaefer, who often pays little heed to party affairs that others consider de rigueur and seldom openly supports other Democratic candidates, stirred a firestorm of criticism at the dinner tonight when word circulated that he had attended a "bull roast" in Dundalk for Rep. Helen D. Bentley.

"It's very difficult to fathom how a Democratic candidate for governor can go to a fund-raiser for a Republican who is targeted for defeat," said state Del. Samuel I. (Sandy) Rosenberg (D-Baltimore). "It's disgraceful."

"Can you believe it?" asked Kathleen Townsend, a Democrat who is challenging Bentley's effort to win a second term from her Baltimore County district. "I suppose he thinks Helen Bentley has been helpful on the Baltimore port."

Sachs, who is trailing Schaefer seven months before the Democratic primary, said that Schaefer's absence and his decision to attend Bentley's roast show "contempt for the party and . . . his arrogance.

"To attend the political fund-raiser of the Republican congresswoman who is being challenged by a gallant underdog, and then not to show up at at the annual function of a party he wants to lead, is outrageous," said Sachs.

Recalling that Schaefer passed up a delegate's seat to the 1984 Democratic national convention and then visited the San Diego zoo, Sachs charged that the mayor has "no attachment to the history, the principles, the soul of the Democratic Party. Whatever else Mayor Schaefer may be, he is not a Democrat."

Mark Wasserman, Schaefer's campaign manager, first dismissed the rumors of his candidate's attendance at the Bentley affair as a sign of Sachs' "desperation."

When informed that Schaefer had attended, Wasserman said that the decision reflected the mayor's "respect for Bentley's contribution to strengthening the port."

Wasserman said Schaefer missed tonight's dinner because of a longstanding commitment to attend a Baltimore Civic Center concert by opera star Luciano Pavarotti.

But even Democrats who are officially are neutral in the governor's race took umbrage at the mayor's move.

Tom McMillen, a candidate for the 4th District congressional seat who is under enormous pressure from organization Democratic leaders to support Schaefer, said, simply: "I wouldn't have done it."