reportingsjr Posted August 18, 2006 Share Posted August 18, 2006 I know this should probably be in the mysql forum but meh.. dont feel like it .I was too lazy to create a topics table and posts table in mysql, so now I have run into any issue.. how do I get it so it only echos out one of each posts? If this isnt possible.. then I have alot more work to do to re format it . I might just start reformatting it now lol..Tell me if this is possible, the way I have it now it just echos out every post with the topic title...EDIT: scratch it, it wont take too much work to reformat it, but is there a way to do this? Link to comment Share on other sites More sharing options...
ThePsion5 Posted August 18, 2006 Share Posted August 18, 2006 Ok, so you want to get the number of topics, but you only have a table holding forum posts with topics as VARCHAR() fields, I'm guessing. You can do that without much of a problem, actually. Just do this: SELECT DISTINCT post_name FROM post_table; Hope this helps Link to comment Share on other sites More sharing options...
reportingsjr Posted August 18, 2006 Author Share Posted August 18, 2006 So distinct will make it so it will only pull one record out of mysql with the post_name row as "wee!"? Thank you! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now