M
Marco
I have a table with about 20.000 records
2725 record has in Field "new" a letter A
of those 2725 two records have in Field "sold" the value True
SELECT * FROM tblA WHERE New="A" AND sold=True;
Gives a correct result of 2
If I put this Sql-string in some BasicCode like
Dim dbsA As Database, rst As recordset
Set dbsA = Currentdb
StrSql = "SELECT * FROM tblA WHERE New=""A"" AND sold=0; "
Set rst = dbsA.OpenRecordset(StrSql)
MyResult = rst.RecordCount
gives a result of 2725
Why?
Marco
2725 record has in Field "new" a letter A
of those 2725 two records have in Field "sold" the value True
SELECT * FROM tblA WHERE New="A" AND sold=True;
Gives a correct result of 2
If I put this Sql-string in some BasicCode like
Dim dbsA As Database, rst As recordset
Set dbsA = Currentdb
StrSql = "SELECT * FROM tblA WHERE New=""A"" AND sold=0; "
Set rst = dbsA.OpenRecordset(StrSql)
MyResult = rst.RecordCount
gives a result of 2725
Why?
Marco