thank you @Skydiver for the information. Yes what I think is SQLDataReader will give me a list for row 1. So in that case I have to create a for loop. This is what I think. Anyway, thank you.
while (rdr.Read())
{
string column = rdr[1].ToString();
int columnValue = Convert.ToInt32(column);
for (--)
So The data I want to retrieve has two columns. I want to get the second column and the values in this column are in...
Thanks for the suggestion. So I want to get the value that is within the SQL table ( for example value of row 2 and col 2 from SQL table). I know that this will be done by SELECT sth. After I have got the value, inside the visual studio C#, I will have to write a program where if this value...
yes, I know how the sql query works. But I don't know how to call stop procedure and where to put my logic whether it is after con.open() or con!=null)
Hello, I am very new to C# and Visual Studio Platform. And the problem I am facing now is that I take the data from SQl and based on that data I have to make a condition let's say if the data from SQL is greater than 5, then I will turn on the light. Could anyone help me how to create this...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.