trouble with this select

Ruslan Zasukhin sunshine at public.kherson.ua
Thu Nov 1 12:31:40 CDT 2007


On 31/10/07 4:51 PM, "Joseph Morgan" <joseph at checkos.com> wrote:

Hi Joseph,

>> depending on the used Valentina version I'm not sure if you're able
>> to use aggregate function in an order by clause. If this will make
>> any difficults, define a table method for the calculation.
> 
> Here's where I came up with:
> 
> SELECT departmentName as 'myDepartmentName',sum
> (itemsales.itemsalesamount) as 'itemsalesAMT'
> FROM departments,itemsales where departments._rowID =
> itemsales.itemsalesdepartmentID
> group by departmentName
> order by itemsalesAMT Desc

So you have got it working with result as you need?  GOOD.

And note, that this query is portable now to any RDBMS :-)


> I have never tried binary links. Does this look like a good canidate
> to use a binary link?

I have not catch - for what exactly?

BinaryLink is just one more link kind.
    in mySQL you did have only Foreign Key kind link.
    in Valentina we have 3 kinds now.


-- 
Best regards,

Ruslan Zasukhin
VP Engineering and New Technology
Paradigma Software, Inc

Valentina - Joining Worlds of Information
http://www.paradigmasoft.com

[I feel the need: the need for speed]




More information about the Valentina mailing list