Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 16 to 17 of 17
06-20-2013, 07:44 PM #16
- Join Date
- Jul 2007
- Thanked 0 Times in 0 Posts
That looks quite a neat solution. Thanks.
One possible problem I can see, though, is that I was hoping to use this query as a view, which would greatly simplify the main query, but I was reading on the MySql help site that views don't allow sub-queries in the From clause.
Is there a way that I could encapsulate this query, so I could call it from the From clause of the main query, which would do the range comparisons of the degree columns with the input parameters, hence a table would need to be returned, rather than a variable from a procedure?
DebbieQuicknEasySalesPro.com - your quick and easy, yet powerful solution for managing your membership site sales, downloads and affiliates.
06-20-2013, 08:20 PM #17
Again, given the complexity of what you are doing, I'd be sorely tempted to use a stored procedure that would put your results into a TEMPORARY TABLE. So you would call the procedure and then use your own code to JOIN to the temp table created by the procedure.
So long as this is all done on the same open connection, the temporary table will (a) be only visible on that connection and (b) remain available until you drop it or until the connection is closed.Be yourself. No one else is as qualified.