| 
		
			
			
				
			
			
				 
			
			
				
			
		 | 
		
			
			
				 
			
				
			
		 | 
	||||
| 
				Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums.  You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact us.  | 
		
		 
		![]()  | 
	
		
			
  | 	
	
	
		
		|||||||
| Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed. | 
| 
		 | 
	Thread Tools | 
| 
			
			 | 
		#1 | 
| 
			
			
			
			 Stephen 
			
		
			
			
			Industry Role:  
				Join Date: Jun 2011 
				Location: Europe 
				
				
					Posts: 840
				 
				
				
				
				 | 
	
	
	
	
		
			
			 
				
				MySql Help
			 
			Ok I have the following tables, what I want to do is select 1 random item from ITEMS for each group in GROUPS. If possible done in 1 query. 
		
	
		
		
		
		
		
	
	ITEMS ID - NAME - DESCRIPTION - GROUP GROUPS ID - TITLE - STATUS Thanks  | 
| 
		 | 
	
	
	
		
                 
		
		
		
		
		
		
		
			
			
		
	 | 
| 
			
			 | 
		#2 | 
| 
			
			
			
			 ( ͡ʘ╭͜ʖ╮͡ʘ) 
			
		
			
				
			
			
			Industry Role:  
				Join Date: Mar 2004 
				
				
				
					Posts: 20,010
				 
				
				
				
				 | 
	
	
	
	
		
		
		
		 I guess your answer lies within gun control in the US. If only there weren't so many gunzzzzzzzzzzzzzzzzzz! 
		
	
		
		
		
		
			
		
		
		
		
	
	Faggot. Suck a cock.  | 
| 
		 | 
	
	
	
		
                 
		
		
		
		
		
		
		
			
			
		
	 | 
| 
			
			 | 
		#4 | 
| 
			
			
			
			 Confirmed User 
			
		
			
				
			
			
			Industry Role:  
				Join Date: Oct 2011 
				Location: Munich 
				
				
					Posts: 411
				 
				
				
				
				 | 
	
	
	
	
		
		
		
		 Code: 
	SELECT * FROM `items` GROUP BY `group` ORDER BY RAND(); 
				__________________ 
		
		
		
		
	
	http://kazymjir.com/  | 
| 
		 | 
	
	
	
		
                 
		
		
		
		
		
		
		
			
			
		
	 | 
| 
			
			 | 
		#5 | 
| 
			
			
			
			 Stephen 
			
		
			
			
			Industry Role:  
				Join Date: Jun 2011 
				Location: Europe 
				
				
					Posts: 840
				 
				
				
				
				 | 
	
	|
| 
		 | 
	
	
	
		
                 
		
		
		
		
		
		
		
			
			
		
	 | 
| 
			
			 | 
		#6 | |
| 
			
			
			
			 Confirmed User 
			
		
			
				
			
			
			Industry Role:  
				Join Date: Oct 2011 
				Location: Munich 
				
				
					Posts: 411
				 
				
				
				
				 | 
	
	
	
	
		
		
		
		 Quote: 
	
 Try this: Code: 
	SELECT * FROM (SELECT * FROM `items` ORDER BY RAND()) x GROUP BY x.group ORDER BY RAND(); 
				__________________ 
		
		
		
		
		
			
		
		
	
	http://kazymjir.com/  | 
|
| 
		 | 
	
	
	
		
                 
		
		
		
		
		
		
		
			
			
		
	 | 
| 
			
			 | 
		#7 | 
| 
			
			
			
			 So Fucking Banned 
			
		
			
			
			Industry Role:  
				Join Date: May 2012 
				Location: Brazil 
				
				
					Posts: 2,056
				 
				
				
				
				 | 
	
	|
| 
		 | 
	
	
	
		
                 
		
		
		
		
		
		
		
			
			
		
	 | 
| 
			
			 | 
		#8 | 
| 
			
			
			
			 Stephen 
			
		
			
			
			Industry Role:  
				Join Date: Jun 2011 
				Location: Europe 
				
				
					Posts: 840
				 
				
				
				
				 | 
	
	|
| 
		 | 
	
	
	
		
                 
		
		
		
		
		
		
		
			
			
		
	 | 
| 
			
			 | 
		#9 | 
| 
			
			
			
			 So Fucking Banned 
			
		
			
			
			Industry Role:  
				Join Date: Jul 2012 
				
				
				
					Posts: 155
				 
				
				
				
				 | 
	
	|
| 
		 | 
	
	
	
		
                 
		
		
		
		
		
		
		
			
			
		
	 |