GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   Filter combining tags (https://gfy.com/showthread.php?t=1350957)

lakerslive 12-26-2021 09:27 AM

Filter combining tags
 
Hello,


i have a custom DB.

It has a table structure called "POST"

in that table POST it has a field called "TAGS" where data like
blonde, brunette, MILF, fit, busty etc.. are all stored.

My question is, is the database structured correctly to enable a filter system on the front end to do a combine tag filter search? example, i only want "BLONDES" with "FIT" bodies? thank you!

sarettah 12-26-2021 01:49 PM

Quote:

Originally Posted by lakerslive (Post 22947466)
Hello,


i have a custom DB.

It has a table structure called "POST"

in that table POST it has a field called "TAGS" where data like
blonde, brunette, MILF, fit, busty etc.. are all stored.

My question is, is the database structured correctly to enable a filter system on the front end to do a combine tag filter search? example, i only want "BLONDES" with "FIT" bodies? thank you!

Without knowing much more:

Select * from tablename where tags like '%blondes%' and tags like '%fit%'

Should work. How well it works depends on your indexing.

I have my models db structured with a models table and a tags table.

The tags table has the model_id and a tag name and there are multiple tag records per model.

.


All times are GMT -7. The time now is 06:32 AM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123