Need help in SELECT query

Discussion in 'MySQL' started by sajjadasif, Jan 27, 2012.

  1. #1
    Hi,

    I want to select rows from the table where this kind of data exist in one column of the row:

    "<img src=https://www.abc.com/abc/images/weblinklop_big.jpg><script type="text/javascript"
    src="http://www.abc.com/affiliateabc/clpolick.js"></script>
    <script type="text/javascript">
    var code ="abc-02611P";
    var unique = get_cookies("ABC");unique = (unique)?unique:"";
    document.write("<script type='text/javascript' src='http://www.abc.com/affiliateabc/affilateabc_detail.php?url="+escape(window.location.href)+"&code="+code+"&unique="+unique+"'><\/script>");
    </script>"

    Actually, I am copying source code of a web page and then store in a table. Now, I want to select those rows which has above string. I tried with LIKE but it couldn't help me. Can you guide me that how can I write a mysql query to get relevant records from a table which has above string.

    Your response is appreciated!! Thanks
     
    sajjadasif, Jan 27, 2012 IP
  2. iama_gamer

    iama_gamer Active Member

    Messages:
    404
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    60
    #2
    You need to provide more details like what the other columns of the table are and where the website name is stored in the first place.
     
    iama_gamer, Jan 27, 2012 IP
  3. mwasif

    mwasif Active Member

    Messages:
    816
    Likes Received:
    23
    Best Answers:
    1
    Trophy Points:
    70
    #3
    Are you sure you have the same data in your table? It is quite possible you have saved data in different format. Do you really have a matching record in your table?
     
    mwasif, Jan 28, 2012 IP
  4. inayah

    inayah Peon

    Messages:
    15
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    could you just select on that table ..without any where condition such as like? Still any error display?
     
    inayah, Jan 31, 2012 IP