CHICAGO (AP) -- Aramis Ramirez kept the game going so long that he gave himself a chance to win it.
Ramirez barely scored on pinch-hitter Troy O'Leary's tying, two-out, two-run double in the 11th. Then in the 14th, Ramirez singled home Sammy Sosa to extend Arizona's team-record road losing streak to 10.
"I was trying to make contact and get the run in," Ramirez said. "You don't want to strike out in a situation with the winning run at third base."
The game ended almost eight hours after the first pitch. By then, most of the announced crowd of 38,738 had left Wrigley Field.
There was a 3-hour, 4-minute rain delay after the sixth inning, ending Curt Schilling's outing for Arizona.
Cubs manager Dusty Baker had one of his starting pitchers warming up and was going to use another starter to pinch-hit if Ramirez hadn't come through.
"We were doing all we could to win that game," Baker said. "We were at the end, and they were pretty close to the end."
The Diamondbacks used six relievers after Schilling was lifted.
Antonio Alfonseca (1-1), the sixth Cubs reliever, pitched three scoreless innings.
Arizona took a 3-1 lead in the 11th on Rod Barajas' two-run single.
The Cubs rallied in the bottom half when Karros and Ramirez singled and O'Leary doubled. Ramirez hustled home, just beating the relay to the plate.
"As soon as he hit the ball over the shortstop's head, I had in mind that I have to score on this play," said Ramirez, acquired in a trade with Pittsburgh less than two weeks ago. "There were two outs, and I had to take a chance."
The Diamondbacks lost for the 11th time in 13 games.
"We are not executing," said Schilling, adding that he wanted to come back out after the rain delay. "We had a chance to win this game tonight multiple times. We didn't make the plays."
Schilling and Juan Cruz were locked in a pitcher's duel before the rains came after the sixth inning with the score tied at 1-all.
Oscar Villarreal took over for Schilling after the delay. Cruz already had been lifted for a pinch-hitter.
Schilling, just 1-3 since returning from a six-week layoff after fracturing bones in his throwing hand, gave up a leadoff infield single to Kenny Lofton before retiring 13 straight.
Schilling gave up one run and four hits in six innings, striking out seven.
Cruz, making his second start since being recalled from Triple-A Iowa for injured Mark Prior, was equally impressive. He set down the first 11 batters he faced.
The Cubs tied it up in the bottom of the inning on Sosa's sacrifice fly.
The fans who were still remaining sang "Take Me Out to the Ball Game" a second time in the middle of the 14th inning. ... Cubs SS Alex Gonzalez is 1-for-19 over his last six games. ... A fan ran on the field during the rain delay and did a belly slide on the tarp before being led away by security.