Tuesday, 15 January 2013

php - Find specific value in comma list in database -


In one of my tables, I have a column where there is a comma separated list of those users who bought that item < / P>

How can I read the list and run a php script, to know if that user is logged on (the session is stored in that list) in that list. For example, how can I see that the user is logged on (MTNOfficial) in the list. I think that this is a php statement with a mysql CONCAT or FIELD_IN_SET or something.

Thanks

Use to search your user's records

  Choose from your_table * where find_in_set ('MTNOfficial', usersBought) & gt; 0    

No comments:

Post a Comment