Forum Replies Created

Viewing 2 posts - 16 through 17 (of 17 total)

  • RE: sum incorrect

    CREATE TABLE [dbo].[Orders](

    [OrderNo] [smallint] NULL,

    [Price] [smallmoney] NULL,

    [Descr] [varchar](50) NULL

    ) ON [PRIMARY]

    GO

    INSERT INTO [Test].[dbo].[Orders]([OrderNo],[Price],[Descr])VALUES(001,30,1)

    INSERT INTO [Test].[dbo].[Orders]([OrderNo],[Price],[Descr])VALUES(001,30,1)

    INSERT INTO [Test].[dbo].[Orders]([OrderNo],[Price],[Descr])VALUES(001,40,1)

    INSERT INTO [Test].[dbo].[Orders]([OrderNo],[Price],[Descr])VALUES(002,20,1)

    INSERT INTO [Test].[dbo].[Orders]([OrderNo],[Price],[Descr])VALUES(002,30,1)

    INSERT INTO [Test].[dbo].[Orders]([OrderNo],[Price],[Descr])VALUES(002,50,1)

    INSERT INTO [Test].[dbo].[Orders]([OrderNo],[Price],[Descr])VALUES(002,42,1)

    INSERT INTO [Test].[dbo].[Orders]([OrderNo],[Price],[Descr])VALUES(003,40,1)

    INSERT INTO [Test].[dbo].[Orders]([OrderNo],[Price],[Descr])VALUES(003,48,1)

    INSERT INTO...

  • RE: sum incorrect

    I have a table that has an OrderNo, Price, and Descr field. The OrderNo is like an acct number. There are multiple records with the same OrderNo. I need to...

Viewing 2 posts - 16 through 17 (of 17 total)