Thanks to all who helped with my earlier SQL question. It was exactly what I needed. But now I'm making it more involved. Tom and Dick are competing salesmen. The data looks like this:

  Tom   Pitch
  Dick  Pitch
  Tom   Sale
  Dick  Sale
  Tom   Pitch

I want to show a list of salesmen, sorted by rate of sales:

  Dick   1 sale in 2 tries, 50.0%
  Tom    1 sale in 3 tries, 33.3%

Is this possible with a single SQL statement? Many thanks,

- Brian

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to