[thelist] SQL subqueries in mySQL 3.23.54

Joshua Olson joshua at waetech.com
Tue Mar 2 08:33:03 CST 2004


> From: Tab Alleman
> Sent: Tuesday, March 02, 2004 9:21 AM
>
> Hmmm, what about UNION-ing a SELECT Grouped by B.id with a SELECT
> Grouped by C.id?  I've never needed to use UNION so I'm not sure of the
> syntax.

You can do that:

SELECT B.id, Count(*)
FROM B
WHERE B.id = 1
GROUP BY B.id
UNION
SELECT C.id, Count(*)
FROM C
WHERE C.id = 1
GROUP BY C.id

Unfortunately, that doesn't get you much closer to the solution.

<tip type="MSDE" author="Joshua Olson">
Microsoft explains how the workload governor works in MSDE here:

http://www.microsoft.com/sql/msde/techinfo/workloadgov.asp

This document explains how you can tell if your usage is triggering the
governor using the following:

DBCC CONCURRENCYVIOLATION

I'm running over a dozen typical small-client websites off one instance of
MSDE (~2000 actual page hits a week each) and have never yet triggered the
workload governor.  Moral of the story: if you need a solid database for a
wintel box, try out MSDE and see if it'll fit your needs.  If it does, it's
a great value since it's FREE!
</tip>

<><><><><><><><><><>
Joshua Olson
Web Application Engineer
WAE Tech Inc.
http://www.waetech.com/service_areas/
706.210.0168




More information about the thelist mailing list