hello,
I have myODBC 5.1 installed and I am trying to acces a database
establishing a connection and executing queries does work
but if I use the following
RS.Open query
rsRows = rsSheet.Range("A1").CopyFromRecordset(RS)
I will not get correct results in rsSheet
my query (simplified):
select distinct
a.val1,
a.val2,
b.val3,
c.val4
from tabA a, tabB b
only a.val1 and a.val2 are copied, everything else is missing.
but if I remove b.val3 from my query then a.val1, a.val2 and a.val4 are copied
the weird thing is that using "MySQL ODBC 3.51 Driver" is working fine. just "MySQL ODBC 5.1 Driver" has problems
the resultset is correct. how do I know? using:
and then iterating through all elements using 2 for loops, will give me correct values
of course you can say to use the for loops, but this does not look nice espacially as there is a function for this purpose, which might also have better performance
plz do not tell me to use version 3.51 because this code is going to be run on other machines where downgrading is no option
Bookmarks