oCommand.Connection.Open() ' Add all command text If oCommandText.Count > 0 Then For Each lcCommandText In oCommandText oCommand.CommandText = lcCommandText oCommand.ExecuteNonQuery() Next End If oCommand.CommandText = tcSQL + " INTO CURSOR Temp" oCommand.ExecuteNonQuery() oCommand.CommandText = "RETURN SETRESULTSET(""Temp"")" oCommand.ExecuteNonQuery() oDataAdapter.SelectCommand = oCommand oDataSet = New DataSet ' By default, .NET does not add the specific field length, which is needed in XML as at the other end ' someone would always get memo field instead of character field oDataAdapter.MissingSchemaAction = MissingSchemaAction.AddWithKey oDataAdapter.Fill(oDataSet)Basically, the RETURN SETRESULTSET line is the one which is not working. I obtain: