For the past three weeks, former Democratic Party chairman William G. Thomas and lobbyists for the Virginia Electric and Power Co. have stalked the hallways of the General Assembly, cornering legislators and lining up votes for their billion-dollar coal-slurry-pipeline bill.

A block down the street, former Republican governor John N. Dalton and other lobbyists hired by the railroads worked the other side. One by one, Dalton called in lawmakers for hour-long chats in his Richmond law office where he argued against the project by showing off a small bottle of filthy water, taken, he said, from a slurry pipeline.

The battle over the pipeline--the Super Bowl of corporate lobbying in Virginia--played today before a crowded House committee room. By the time it was over, the railroads had smashed Vepco with the ferocity of John Riggins tearing through the Dolphins' line.

"It's flushed like sewage -- down the tubes," gloated Houston W. Kitts, the lobbyist for the United Transportation Union, after Vepco's slurry bill was trounced in a surprise 14-to-5 committee vote. "There's been more intense lobbying on this than anything I've ever been associated with."

The vote in the House Corporations, Insurance and Banking Committee does not necessarily finish off the pipeline issue for this year's session. An alternative pipeline bill--proposed by Southwest Virginia lawmakers with the backing of the coal industry--was deadlocked in committee 10-to-10, while another bill proposing a $200,000 study of the pipeline has not been voted on.

But given the opposition of Gov. Charles S. Robb to any pipeline action this session, there appeared little chance that the controversial project would get the green light before the legislature goes home Feb. 26. If that is the case--and even the coal industry's chief spokesman acknowledged today that chances for switching votes were "remote" -- Vepco may have only itself to blame, many legislators said.

The state's biggest utility has pulled out all the stops for the pipeline, a massive project that would pump a mix of pea-sized crushed coal and water from the coal mines of southwest Virginia to its Tidewater power plants. Since its efforts began, the utility had flown leading legislators on an expense-paid "inspection" trip to Arizona, shown coal-slurry movies, and sent out mass mailings to its 90,000 stockholders and 12,500 employes in an effort to win public support.

In conjunction with Transco Energy Co. of Houston, Vepco also hired a stable of some of the capital's higher-priced advocates, including Thomas, a top political adviser to Robb, and E.H. (The Judge) Williams, the portly veteran lobbyist for the trucking industry.

Curry A. Roberts, a former political aide to Democratic Lt. Gov. Richard J. Davis, was hired to run the newly formed "Virginians for Competitive Coal Transportation," which bombarded lawmakers and the media with press releases and Vepco-financed consultants' studies.

But in the end, the company suffered from what many legislators called a public relations blunder, requesting a $105.7 million fuel-charge increase the day before its prized bill finally came to a vote. Legislators said the requested 5.2 percent increase brought a groundswell of hostility against Vepco rushing to the fore.

"The timing on that request was awful; a lot of people were talking about it," said Del. V. Thomas Forehand (D-Chesapeake), who voted against the pipeline. "It definitely clouded the issue," added Del. Kenneth R. Plum (D-Fairfax). "Whenever my constituents write me a letter, they always put in a dig at Vepco."

The railroads, who view the pipeline as a threat to their coal-carrying monopoly, have been fierce in opposing the project. Last week, they held two huge dinners at Richmond's Commonwealth Club for all members of the legislature and their wives.

The Richmond-based CSX Corp. retained the prominent Richmond law firm of McGuire, Woods, and Battle. The firm's best known member, Dalton, who also sits on the CSX board, quickly began calling GOP legislators to set up appointments in his office.

"When he called me, I told him, 'You're the lobbyist, you come see me,' " said Del. Warren E. Barry (R-Fairfax). "He said: 'I was governor, I can't go roaming the halls down there.' "

Dalton brushed aside charges by Democrats that it was improper for a former Virginia governor to be lobbying. "I've talked to probably half the members of the legislature," Dalton said in a telephone interview. "When somebody's trying to take a substantial part of your business away, you just can't sit back and be idle."

Dalton played on environmentalists' worries about the pipeline with the bottle of dirty water on his coffee table. "It's terribly dirty," Dalton said. "I wanted them to see this is what drinking water would be like if the pipeline were built ."

The primary focus of today's hearing was a bill, drafted by Thomas' law firm and introduced by Del. Warren G. Stambaugh (D-Arlington). It would empower the State Corporation Commission to grant permits for construction of a slurry pipeline provided that certain environmental concerns, such as contaminated water, were addressed.

A coal slurry pipeline, Stambaugh said, would be "the most efficient and cheapeast way to transport coal" and eventually help to hold down utility rates. But many legislators were not sure they had digested all the arguments.

"There was much too much pressure to put through something like this in one session," said Del. Gladys B. Keating (D-Fairfax), who voted against the bill. "It was just too complex."