You are here: Re: Exotic SQL Question « MsSQL Server « IT news, forums, messages
Re: Exotic SQL Question

Posted by jsfromynr on 10/01/44 11:47

Hi There,

You can use somewhat Celko Suggested ,
SELECT C1.color_nbr, W1.zeller_nbr, C1.color_name, W1.weekday_name
FROM Colors AS C1, Weekdays AS W1
WHERE zeller_number
= (SELECT MAX(zeller_nbr)
FROM Weekdays AS W2
WHERE W2.zeller_nbr < C1.color_nbr
AND W2.zeller_nbr = W1.zeller_nbr)

You my try this

Select * From
DayTable AA , ColorTable BB
Where AA.id1>BB.id1
And BB.id1 = ( Select Max(id1) From ColorTable BB1 where BB1.id1 <
AA.id1)

With Warm regards
Jatinder Singh

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация