Jump to content

[SOLVED] Find override


ramli

Recommended Posts

I have the following querys:

 

query1:

SELECT * FROM gebruikers INNER JOIN klas ON gebruikers.Klas_ID = klas.Klas_ID WHERE Actief = '1' AND Gebruikersrol = '2' AND Jaar = '2009'

 

query2:

SELECT * FROM gebruikers INNER JOIN klas ON gebruikers.Klas_ID = klas.Klas_ID WHERE Gebruikersnaam LIKE '%raman%' OR Voornaam LIKE '%raman%' OR Achternaam LIKE '%raman%' OR Tussenvoegsel LIKE '%raman%' OR Klasnaam LIKE '%raman%' AND Actief = '1' AND Gebruikersrol = '2' AND Jaar = '2009'

 

When i add the FIND to the query it ignores the Gebruikersrol, Actief and Gebruikersrol restriction and display's all records. I want to search the database with the restrictions in place.

 

What am i doing wrong? any help will be much apreciated.

Link to comment
https://forums.phpfreaks.com/topic/140319-solved-find-override/
Share on other sites

Looked it up in the dictionary and tryed..

 

SELECT * FROM gebruikers INNER JOIN klas ON gebruikers.Klas_ID = klas.Klas_ID WHERE (Gebruikersnaam LIKE '%test%' OR Voornaam LIKE '%test%' OR Achternaam LIKE '%test%' OR Tussenvoegsel LIKE '%test%' OR Klasnaam LIKE '%test%') AND Actief = '1' AND Gebruikersrol = '2' AND Jaar = '2009'

 

and it works perfectly.

 

Thx for the help.

Link to comment
https://forums.phpfreaks.com/topic/140319-solved-find-override/#findComment-734262
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.