Forum Replies Created

Viewing 15 posts - 31 through 45 (of 69 total)

  • RE: SQL Server Management Studio

    Got it. Thanks.

    I have been playing around with it a bit and maybe I need to explore it a bit more. I could very quickly view the contents of a...

  • RE: Best Practices

    Also, I heard that SQL 2005/Yukon will have a PIVOT operator. Do you know when this will be released?

  • RE: Best Practices

    I absolutely agree with you. Say, I was thinking of designing my table as follows:

    I would design my table as follows:

    student_id(pk)

    class_id(pk)

    month(pk)

    year(pk)

    day1

    day2

    day3

    day4

    .......

    day31

    And my view would look like:

    Class_id: n

    ...

  • RE: Best Practices

    Yes, I would have part-timers. But as I mentioned earlier, based on the current cost of the storage, I wouldn't mind writing a large row with a whole bunch of...

  • RE: Best Practices

    Yes, I would have part-timers. But as I mentioned earlier, based on the current cost of the storage, I wouldn't mind writing a large row with a whole bunch of...

  • RE: Best Practices

    The month and the year would be defined as columns.

  • RE: Appending data

    I chose the DTS package route. Thx.

  • RE: Splitting a table into two

    I am getting an error on:

    update tblSponsor set

    intAddressID = (select a.intAddressID

    FROM tblAddress as a, tblxxx x

    WHERE ((x.SponsorID = CAST(a.nvcASLMU AS int))

    and (a.nvcASCU = 'aaa')))

    saying:

    Server: Msg 512, Level 16, State 1,...

  • RE: Splitting a table into two

    yes..it has no pk defined

  • RE: Splitting a table into two

    It inserts all the records first, say there were 1000 records. It then gets SCOPE_IDENTITY() (which will return 1000) and then updates the tblSponsor.

    Instead, what I want is to...

  • RE: Splitting a table into two

    Thanks for the tip.

    The following SP ALWAYS updates the intAddressID column in tblSponsor with the same value that is the last identity generated.

    CREATE PROCEDURE dbo.Sponsor_Create_Address

    AS

    SET NOCOUNT ON;

    DECLARE @intAddressID int;

    INSERT INTO...

  • RE: Splitting a table into two

    CREATE PROCEDURE dbo.Sponsor_Create_Address

    AS

    SET NOCOUNT ON;

    DECLARE @intAddressID int;

    INSERT INTO tblAddress(sintAddressTypID,

    nvcAddress1,

    nvcAddress2,

    nvcCity,

    chrStateCode,

    nvcZip,

    nvcASCU)

    select 4,

    AddressLine1,

    ...

  • RE: Splitting a table into two

    CREATE PROCEDURE dbo.Sponsor_Create_Address

    AS

    SET NOCOUNT ON;

    INSERT INTO tblAddress(sintAddressTypID,

    nvcAddress1,

    nvcAddress2,

    nvcCity,

    chrStateCode,

    nvcZip,

    nvcASCU)

    VALUES(

    select 4,AddressLine1,

    ...

  • RE: Splitting a table into two

    The address table is a common table to hold different types of addresses. tblSponsor is just one table. There will be more tables having addresses for which this table will...

Viewing 15 posts - 31 through 45 (of 69 total)