Problem whit DBRW

  • Thread starter Thread starter David8
  • Start date Start date
D

David8

Hi,
When i test this code in Access and in my FP i've no problem, but in the web
site it says there's no posible to show the values. Why??
SELECT Tabla1.nombre
FROM Tabla1, Tabla2
WHERE Tabla1.nombre like (select "*" & Nombre & "*" from Tabla2)

Thannks,
David8
 
Yes, all the site runs on ASP with FP and Access, i've a lot of queries but
only whith this one this type ofe query i've problems.
 
Hi,
Looks like what you want is a join - this would be the usual way to do it

SELECT T1.Nombre
FROM Table1 T1 INNER JOIN Table2 T2 ON T1.Nombre = T2.Nombre

This will give you all values for T1.Nombre that exists in Table 2. Is that
the sort of thing you want to do?

Cheers,
Jon
 
Hi,
That's not exactly, because i want not find all the word.
If for example i've a list a names like this:

Smith
Peter
Casmesth
Josepth

I want the use put only "Sm" and the query returns all the names who
contains this letters, in the begin of the name, inthe middle or in the end.

Thanks,
David8.
 
Then you need to add a WHERE clause.
Something like this:
WHERE T2.Nombre LIKE & VAR &
VAR should be a variable that contains what is searched on.

Regards Jens Peter Karlsen.
 
Back
Top