error 'there is already an open datareader associated with this command which must be closed first'

后端 未结 12 2300
情话喂你
情话喂你 2020-12-05 10:15

runtime error \'there is already an open datareader associated with this command which must be closed first\'

objCommand = new SqlCommand(\"SELECT field1, fi         


        
12条回答
  •  感动是毒
    2020-12-05 10:49

    Option 1: Must execute query and load data before running another query.

    Option 2: Add MultipleActiveResultSets=true to the provider part of your connection string. See the example below:

    
    

提交回复
热议问题