。其中:РPr_GetVotes 从投票项目表Votes中获取所有投票项目的信息;РPr_GetSingleVote 从投票项目表Votes中获取某一条投票项目的信息;РPr_AddVote 添加一条新记录到投票项目表Votes中;РPr_UpdateVote 更新参与投票项目的票数;РPr_DeleteVote 从投票项目表Votes中获取删除一条投票项目信息。Р以上各存储过程的程序代码如下: /* 存储过程Pr_GetVotes */РCREATE PROCEDURE Pr_GetVotesРASРSELECT * FROM Votes ORDER BY VoteIDР/* 存储过程Pr_GetSingleVote */РCREATE PROCEDURE Pr_GetSingleVoteР(@VoteID int)РASРSELECT Votes.* FROM Votes WHERE VoteID = @VoteIDР/* 存储过程Pr_AddVote */РCREATE PROCEDURE Pr_AddVote(@Item varchar(100))РASРINSERT INTO Votes(Item,ItemCount) VALUES(@Item,0) RETURN IdentityР/* 存储过程Pr_UpdateVote */РCREATE PROCEDURE Pr_UpdateVote (@VoteID int)РASРUPDATE Votes SET VoteCount = VoteCount + 1РWHERE VoteID = @VoteIDР/* 存储过程Pr_DeleteVote */РCREATE PROCEDURE Pr_DeleteVote (@VoteID int)РASРDELETE VotesРWHERE VoteID = @VoteID