
Announcement
Collapse
No announcement yet.
Quick mysql/php Noob Question
Collapse
X
-
Just to let you know i have actully solved the problem, it was down to not thinking about the database design enough which i then solved by having multiple queries instnead of just the one
-
well its actully on my laptop apache server and i don't want to upload it because it could be used to bring the server load super high lol.
Leave a comment:
-
I am pretty sure it needs to be a while loop though because in some tables there are multiple results for one event.
Leave a comment:
-
The only reason it would display the content over and over again is because you're using a while loop.
Code:while($var = $mysql_fetch_array($desults)){ echo "content here"; }
Code:$var = $mysql_fetch_array($desults); echo "content here";
Leave a comment:
-
Here you go and thanks again for the help
PHP Code:$desult = mysql_query("
SELECT * FROM Band,B_Event_Appearances,Event,S_Event_Apperances,Songs,Venue
WHERE B_Event_Appearances.Band_ID = Band.Band_ID AND
B_Event_Appearances.Event_ID = Event.Event_ID OR Event.Event_ID =
S_Event_Apperances.Event_ID OR S_Event_Apperances.Song_ID = Songs.Song_ID AND
Event.Venue_ID = Venue.Venue_ID AND Event.Event_ID = $_GET[event_ID]")
or die(mysql_error());
Last edited by Bratac; Fri 9 Sep '05, 6:31am.
Leave a comment:
-
Post your whole query string, there's probably something missing/extra/odd in there
Leave a comment:
-
That helped somewhat, now it displays information when it is suppose to but it will display it over and over and over again until eventually by browser crashes lol. I am unsure why but thanks for your helpit got me alittle closer
.
Leave a comment:
-
Quick mysql/php Noob Question
Hey,
I have a mysql query in a php script. The query simply goes something like this.
select * from blah,blahed,doo,boo where blah.blahid = blahed.blahid and doo.doid = boo.doid etc...
The problem i have come across is that it only displays results which have enteries in all the tables listed in the query. I would like the query to display an entry even if there is not data for it in the doo and boo table. Any ideas on how this can be achieved?Tags: None
widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
Leave a comment: