Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Can I Use SQL To Report Summary Data
Message
 
 
To
13/11/2006 16:22:19
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01169288
Message ID:
01169345
Views:
11
>Thanks everybody. This is what I came up with after my post. It seems that I wasn't to far off. Thanks again!

Jeff,

Once again, you don't have to check for ranges
...
	PADR(ICASE( ;
			nborrower_number_of_employees >= 250, "250 ") ;
			nborrower_number_of_employees >= 100, "100 - 249",;
			nborrower_number_of_employees >= 50, "50 - 99",;
			nborrower_number_of_employees >= 25, "25 - 49",;
			nborrower_number_of_employees >= 10, "10 - 24",;
			                      "0 - 9"), 10) as cRange ,;
	ICASE( ;
			nborrower_number_of_employees >= 250, 6 ;
			nborrower_number_of_employees >= 100, 5,;
			nborrower_number_of_employees >= 50, 4,;
			nborrower_number_of_employees >= 25, 3,;
			nborrower_number_of_employees >= 10, 2,;
					     1) as nPrint_Order ;
     FROM loan
--sb--
Previous
Reply
Map
View

Click here to load this message in the networking platform