SELECT
A.ID,A.FIELD1,A.FIELD2, B.FIELD1,B.FIELD2, B.FIELD1,B.FIELD2, B.FIELD1,B.FIELD2
FROM a
INNER JOIN B
ON a.id = b.a_id
ORDER BY a.field2 ASC, b.field1 ASC ;
- Reply message -
From: "R. Smith"
Date: Fri, May 13, 2011 12:00 pm
Subject: [SQL] Sorting data based fie
Can you provide An example?
Best,
Oliveiros
Enviado via iPhone
Em 13/05/2011, às 04:00 PM, "R. Smith" escreveu:
> Hi,
>
> I am looking for a way to sort data returned from two tables with the
> first sort based on a field from table A and the secord sort based on
> the results of the first so
Hi,
I am looking for a way to sort data returned from two tables with the
first sort based on a field from table A and the secord sort based on
the results of the first sort but the sort field is from table B.
While I can sort on either fields from either table, I cannot get it
to work on both. I