Results 1 to 2 of 2

Thread: including a row in SQL results based on references within string

  1. #1
    Join Date
    May 2011
    Posts
    13

    including a row in SQL results based on references within string

    Here is what my table looks like

    postID|Message
    1| I can't wait to get STARTED!!!!
    2| @1 dude, you're way to hyped
    3| Everyone ignore this guy --> @2
    4| @3 Why ignore me?

    is it possible to do a query where I can fetch all comments chained to post #4?
    Conceptually:
    if I ask for things chained to #4 the mysql will see "@3" (with the symbol '@') and include that in the results, but it will also look at post #3 and include post 2 because of the "@2" included... and all the way down to 1.

    Is it possible to do this with 1 mySql query?

    I can specify the targeted posts in a different field if I need to ( It's possible to have multiple post references though)

    SEOT: 7gNI4bk8OeuPJmaWpb2u

  2. #2
    Join Date
    Dec 2011
    Posts
    1

    At Rangpursoft we pride

    At Rangpursoft we pride ourselves on being able to help our clients with all their needs. Not only will we design top quality websites but we can also help you move your business forward. We are aware that all business needs marketing and for that reason we can help with all elements of your marketing from SEO to leafleting. In addition we can help you with all your print needs. As well as designing all of your business stationary and marketing material we can arrange printing and have the products delivered directly to your door. We are aware that every client has different needs and we aim to give a personal service and exactly tailor a package for each client's needs. By doing this we are able to build long standing relationships with clients that last for many years.

Similar Threads

  1. Need References
    By smarket in forum Web Design, HTML Reference and CSS
    Replies: 0
    Last Post: 30 Aug 2010, 02:32 PM
  2. Problem Paging Results with SQL Server 2008 / PHP
    By kdc_landrover in forum Client & Server Side Scripting (PHP, ASP, JavaScript)
    Replies: 0
    Last Post: 29 Oct 2009, 09:03 AM
  3. MS SQL 2005 Web-Based Admin
    By myLittleTools in forum Client & Server Side Scripting (PHP, ASP, JavaScript)
    Replies: 0
    Last Post: 02 Oct 2006, 09:43 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •