Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9014183
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T03:26:55+00:00 2026-06-16T03:26:55+00:00

I am setting values in my database for tourneyID,Selected,Paid,Entered,date then separating each selection with

  • 0

I am setting values in my database for tourneyID,Selected,Paid,Entered,date then separating each selection with a colon

So I have a string that may look like this

    187,S,,,09-21-2013:141,S,,,06-21-2013:144,S,,,05-24-2013 

but it also could look like this

    145,S,,,07-12-2013:142,S,,,05-24-2013:187,S,,,09-21-2013

and some times is looks like this

    87,S,,,07-11-2013:125,S,,,06-14-2013

I am trying to find this sequence: 187,S,,,09-21-2013

I have data stored like that because I paid a programmer to code it for me. Now, as I learn, I see it was not the best solution, but it is what I have till I learn more and it is working.

My problem is when using LIKE it returns both the 187 and 87 values

    $getTeams = mysql_query("SELECT * FROM teams 
    WHERE (team_tourney_vector LIKE '%$tid,S,P,,$tourney_start_date%' 
    OR team_tourney_vector LIKE '%$tid,S,,,$tourney_start_date%') 
    AND division='$division'");

I tried this using FIND_IN_SET()
but it would only return the the team id for this string

187,S,,,09-21-2013:141,S,,,06-21-2013:144,S,,,05-24-2013

and does not find the team id for this string

145,S,,,07-12-2013:142,S,,,05-24-2013:187,S,,,09-21-2013

   SELECT * FROM teams WHERE FIND_IN_SET('187',team_tourney_vector) AND (team_tourney_vector LIKE '%S,,,09-21-2013%')

Any thoughts on how to achieve this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T03:26:56+00:00Added an answer on June 16, 2026 at 3:26 am

    Here is my solution to the problem above using RLIKE

        $tourney_start_date=date('m-d-Y', strtotime($tourney_start_date));
        $vector = '"'.$tid.',S,,,'.$tourney_start_date.'"';
        $getTeams = mysql_query("
        SELECT * FROM `teams` 
        WHERE `team_tourney_vector` 
        RLIKE $vector 
        AND division='$division'");
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a setting stored in database which has a value .jpg|.gif|.png . I
I have variable @count of datatype int.I am setting values to this @count. I
I am setting two values based on two different conditions inside for each. Is
I have an external setting file which has some nodes holiding attribute values of
I have a ListView that I'm populating with values from my database. If the
I have this form which can insert/update values into database table. <div id=settingsdiv style=width:350px;
I have an external database that obviously is storing some data. I am setting
In setting up a MySQL database, consider that I have a table of products
I am dynamically creating forms based on values in a database. Each form element
i have a navigation element that is determined by values in a database. no

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.