📌  相关文章
📜  如果 vlaue 存在,则不要输入事件 c# 代码示例

📅  最后修改于: 2022-03-11 14:48:47.031000             🧑  作者: Mango

代码示例1
public bool rebateslip(int ticketID)
{
    SqlCommand myCommand  = new SqlCommand("SELECT ID FROM ticket WHERE ID = @ticketID", con);
    SqlDataAdapter sqlDa = new SqlDataAdapter(myCommand);

    myCommand.Parameters.AddWithValue("@ticketID", ticketID);
    var reader = myCommand.Execute();
    return reader.HasRows;    
}