SqlCommand read one value

后端 未结 2 1274
情书的邮戳
情书的邮戳 2020-12-21 15:21

I have a problem with the value returned from SqlCommand, I have this code:

string sqlSelect = \"Select TOP 1 Quotation.SentToSupp as SentToSupp         


        
2条回答
  •  我在风中等你
    2020-12-21 16:23

    Use SqlCommand.ExecuteScalar method - Executes the query, and returns the first column of the first row in the result set returned by the query. Additional columns or rows are ignored.

提交回复
热议问题