|
Posted by bevanward on 06/15/06 03:12
Hi Mike
Thanks for your comment - C is the field in the target table of the
insert that I was hoping would increment in the same sequence as the
sort of Aa, Ll
Cheers
Bevan
Mike C# wrote:
> Try ORDER BY C
>
>
> <bevanward@gmail.com> wrote in message
> news:1150338610.291820.67350@h76g2000cwa.googlegroups.com...
> > Hi All
> >
> > I am finding unexpected results when inserted into a newly created
> > table that has a field of datatype int identity (1,1).
> >
> > Basically the order I sort on when inserting into the table is not
> > reflected in the order of the values from the identity field.
> >
> > Have I been wrong in assuming that it should reflect the order from the
> > sort?
> >
> > The code is ...
> >
> > create table tmp (A varchar(50), L float, C int identity(1,1))
> > insert into tmp (A, L) select Aa, Ll from tmp1 order by Aa, Ll
> >
> > and I don't understand why the values in tmp.C aren't in the order
> > suggested by the sort.
> >
> > Any comments most appreciated
> > Bevan
> >
Navigation:
[Reply to this message]
|