[Gambas-user] Datasource.Filter does not work
Martin McGlensey
mmcg29440 at ...3163...
Thu Nov 6 22:04:33 CET 2014
Hello,
Using Gambas 3.6.1 on Ubuntu 12.04. I have a datatable called "tblUsers"
with the following columns: Record_No, User, Password and last_Update.
Record_No is the primary index. I have verified that there are two records
in the datatable. Have the following code:
Login.Connection = hConn
Login.Table = "tblUsers"
Login.Sort "User"
This populates two datacontrols within the datasource container Login. That
works because I see the data in the datacontrols and it is correct. I know
the value 'Marty' is in the field 'User' in the table.
Now further down in a sub login.Filter = "User = " & txtLogin.Text, where
txtLogin.Text = "Marty", I get "query failed, unknown column 'Marty' in
where clause"
This syntax used to work as I have it in other modules that I have tested
previously. Now they also do not work as before. The Wiki says the syntax is
like the where clause. So it should work as I have written it. Where have I
gone wrong?
Thanks,
Marty
More information about the User
mailing list