Q:

ExecuteScalar() with more than 1 value returned

I want return my query = "show database "
and then this my code
dim conn as conn.connectionstring = Myconnection
dim Mydb as new Mysql.data.mysqlclient.mysqlcommand(myquery,conn)
conn.open
textbox2.text = convert.tostring(mydb.excutescalar())

and my output is :

infomationschema
mysql
test

A:

Now I've found a way
the following code
Dim myQuery As String = "show databases"
TextBox1.Text = "localhost"
    constring = "server=" & TextBox1.Text & ";" _
    & "uid=root;" _
    & "pwd=admin;" _
    & "database=mysql;"
    Try
        conn.ConnectionString = constring
        Dim myDb As New MySql.Data.MySqlClient.MySqlCommand(myQuery, conn)
        conn.Open()
        ComboBox1.Text = "select database"
        'myDb.Connection.Open()
        'TextBox2.Text = TextBox2.Text + Convert.ToString(myDb.ExecuteScalar())
        Dim myReader As MySql.Data.MySqlClient.MySqlDataReader = myDb.ExecuteReader()
        Try
            While myReader.Read
                ComboBox1.Items.Add(myReader.GetString(0))
            End While
        Finally
            myReader.Close()
            conn.Close()
        End Try

    Catch ex As Exception
        MessageBox.Show(ex.Message)
    End Try

and then my output 

