deepakaa
01-12-2004, 07:32 AM
hi guys....
i m using following sql statement to search in two tables of database which r connected by the field 'numeroperation' ....
mysql = "SELECT recevoi.date, recevoi.description, recevoi.numeroperation, recevoi.societe, piece_indice.nompiece, piece_indice.numeropiece, piece_indice.indice,piece_indice.concerne,piece_indice.valablepour FROM recevoi, piece_indice "
strfiltre = "recevoi." & cmbsearchfiltre.Text
Set rs = cn.Execute(mysql & "where recevoi.societe = '" & cmbsearch.Text & "' and recevoi.numeroperation = piece_indice.numeroperation and strfiltre = '" & cmbfiltre.Text & "'")
here i m using variable 'strfiltre' as string which is creating a problem...
this statement is currently not working...pls tell me what is the problem and can i use the string variable as i have used it here...and if no, pls tell me anyother way of performing search using unknown criteria selected by the user.....
thanx.
i m using following sql statement to search in two tables of database which r connected by the field 'numeroperation' ....
mysql = "SELECT recevoi.date, recevoi.description, recevoi.numeroperation, recevoi.societe, piece_indice.nompiece, piece_indice.numeropiece, piece_indice.indice,piece_indice.concerne,piece_indice.valablepour FROM recevoi, piece_indice "
strfiltre = "recevoi." & cmbsearchfiltre.Text
Set rs = cn.Execute(mysql & "where recevoi.societe = '" & cmbsearch.Text & "' and recevoi.numeroperation = piece_indice.numeroperation and strfiltre = '" & cmbfiltre.Text & "'")
here i m using variable 'strfiltre' as string which is creating a problem...
this statement is currently not working...pls tell me what is the problem and can i use the string variable as i have used it here...and if no, pls tell me anyother way of performing search using unknown criteria selected by the user.....
thanx.