Hi All,
May I know who to write correct looping function on dataset?Condition:
Table = customer_prod
Data:
Cust_name Cust_Item Price
A A100 180
A B100 100
B A100 50
I want to write my script to loop for cust_name = A
My sample code:
conn.ConnectionString = constr
cmd.Connection = conn
cmd.CommandType = CommandType.Text
cmd.CommandText = " select * from customer_prod where Cust_name = "A" '"
l_Adapter = New SqlDataAdapter(cmd)
sda = New DataSet
l_Adapter.Fill(sda)
-----For Each Row As DataRow In sda.Tables(0).Rows ---how to write correct one??? here i got error..
next