SQL queries

From: SexyMF <sexymfDELETETHIS_at_flashmail.com>
Date: Sat, 10 Feb 2001 06:37:36 GMT
Message-ID: <3a84dae5.1441887_at_pubnews.netcom.net.uk>


  1. How do I put in todays date into a mySQL field? ie., I can get todays date via `date`, but how do I convert it to the weird mySQL format?
  2. How do I replace a particular piece of data - eg a field say - "no. of pizzas sold today" - 1, when another one gets sold, it should become "2" ?
  3. How do I sort a table by the number of entries there are of a particlar piece of data? eg, if this is my table

  team | matchwon | datewon | timeswon
Lakers		Superbowl       2000/5/3		3
Muggles		Slamdunk	3003/4/12		2
Muggles		Superbowl	4002/2/2		1
Ballhedz	HotMatch	3000/4/11		2

, when I run whatever SELECT function, I want this to show up:



Muggles

Ballhedz

Lakers

How do I do that?

Thanks for all your replies,

SMF.                         

-- 
"Unix is not designed for desktop applications, period."
- Frans Bouma, comp.sys.ibm.pc.demos, Oct 28,2000.
Received on Sat Feb 10 2001 - 07:37:36 CET

Original text of this message