SAN DIEGO (CNS) - A man accused of stabbing a fellow trolley rider in the neck, then carjacking a vehicle from a 75-year-old man near Old Town, must stand trial on attempted murder and other charges, a judge ruled Monday.

Following hs preliminary hearing at the downtown courthouse, 54-year-old Gregory Charles Davis entered a plea of not guilty by reason of insanity. Davis will be examined by a court-appointed psychologist and psychiatrist before proceeding to trial.

If convicted and found insane, Davis could be sent to a state mental hospital. If a jury finds him sane, he faces 15 years in prison if convicted.

Kirstie Moss testified that Davis was agitated while in the back of the trolley about 12:30 p.m. last Sept. 26 when he came down the aisle, yelled something and stabbed James Novae in the neck. Novae suffered a life-threatening wound and had to have emergency throat surgery.

"It was just out of control," Moss testified.

Juanita Johnson, who was also on the trolley, said Davis was acting a little strange and did not appear to be mentally stable when he stabbed the victim. The defendant and the victim apparently knew each other.

Once off the trolley, Davis confronted a 75-year-old man near Perry's Cafe, demanding the keys to his Buick, said prosecutor Christopher Moon. Davis then allegedly punched the man and drove off recklessly, causing two hit-and-run accidents, according to the prosecutor.

Shortly before 3 p.m., a television news cameraman driving through Clairemont Mesa spotted the stolen Buick abandoned alongside the southbound lanes of Interstate 805, near Mesa College Drive.

Officers with a service dog searched a brushy open area into which the carjacker apparently had fled after pulling over on the freeway. About 4 p.m., police took Davis into custody off the 7800 block of Mission Center Road.

San Diego police Detective Donald Williams testified that Davis told him that he had been riding the trolley to Ocean Beach to take a shower.Davis said gangsters or U.S. marshals were on the trolley trying to make a case against him, and that he hit someone with a box cutter, Williams testified.

The defendant admitted stealing the car near Old Town and getting into an accident, the detective said.

"He said he felt bad about taking the old man's car," Williams testified.

Williams said Davis had a disorganized thought pattern while speaking to him and said he was defending himself when he stabbed the man on the trolley.

In addition to attempted murder, Judge John Einhorn ruled that enough evidence had been presented for the defendant to also stand trial on charges of carjacking, elder abuse and two misdemeanor counts of hit-and-run.

A readiness conference is set for Jan. 26.