Help!!!
I cannot get my combo box to populate using a select statement from mysql database.
Please see below for coding
CN = New ADODB.Connection
'Connecion to database
CN.Open("driver={mysql odbc 5.1 driver};server=localhost;database=v_control;user=root;password=;option=3")
RS = New ADODB.Recordset
RS.Open(SQLdata, CN, ADODB.CursorTypeEnum.adOpenUnspecified, ADODB.LockTypeEnum.adLockPessimistic)
If DBconnect() = True Then
SQLSearch("select * from engineer (EngineerNumber")
RS.MoveFirst()
While RS.EOF = False
Do
cmbEngNum.Items.Add("EngineerNumber")
RS.MoveNext()
Loop
End While
End If
but this reports the following error
[MySQL][ODBC 5.1 Driver][mysqld-5.1.36-community-log]You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '(EngineerNumber' at line 1
Any ideas would be most appreciated, im quite new to this as you can probly tell.
thanks