Forum Replies Created

Viewing 15 posts - 7,726 through 7,740 (of 10,144 total)

  • RE: Can we have more than one identity columns in a table

    diva.mayas (6/29/2010)


    Hi

    Can we have more than one identity columns in a table.

    if yes then why, if no then why

    i am interested to know the reasons behind it....

  • RE: Selecting a certain number of a records from certain types of records

    You're getting there, but you need to take another look at your tables, there should be many more than the two listed. I'd guess about 15.

    For instance:

    Table StationVehicles

    StationVehTypeID VehicleTypeStation...

  • RE: Are the posted questions getting worse?

    Paul White NZ (6/29/2010)


    Too many of the players seem to be to be over-paid, under-talented, whining, cheating prima donnas.

    Well said Paul, couldn't agree more.

  • RE: datetime difference and display in years

    scottichrosaviakosmos (6/29/2010)


    i want to get date difference like a start date and end date and find difference in years but i want like if for example one date is 2007...

  • RE: order by twice

    Kingston Dhasian (6/29/2010)


    No idea why the OP is getting an error.

    Me neither Kingston but it's always nice to have an alternative.

  • RE: order by twice

    eng.khiat (6/29/2010)


    SELECT * FROM

    (

    SELECT top 10 * FROM tableX ORDER BY ID DESC

    ) AS A

    ORDER BY A.ID ASC

    It gives error and when i searched...

  • RE: Select Distinct

    Potso, none of your sample data posts match up with each other, the column names and contents are all over the place, and your query would generate an error if...

  • RE: Duplicate recods using SSIS

    Import the contents of the flat file into a staging table in your db. Assume the data is dirty.

    Perform any necessary validation against the staging table - including dupe-flagging.

    Transfer...

  • RE: i need a query tip

    canuzun (6/28/2010)


    Thanks for the tip.

    Only curious, is it possible to create the second table, from the first one with single query?

    Of course. SELECT...INTO...FROM...

    Best practice is to check for existence of...

  • RE: Today's Random Word!

    Coffindodger

  • RE: check for NULL in a column

    priya__ (6/28/2010)


    Thanks all for your reply,

    I cannot use SUM as I am counting a Key column here and if I use sum it will sum up the columne instead...

    I have...

  • RE: check for NULL in a column

    Or this way:

    ;WITH FastAggregate AS (

    SELECT , col1, COUNT(*) AS RowCounts

    FROM table1

    GROUP BY , col1

    )

    SELECT ,

    SUM(CASE WHEN col1 IS NULL THEN RowCounts END) AS 'nullcnt',

    SUM(CASE WHEN col1...

  • RE: check for NULL in a column

    Gianluca Sartori (6/28/2010)


    Sorry for echoing, Gail...

    Et tu, Gianluca.

  • RE: check for NULL in a column

    The simple CASE uses equivalence: CASE i WHEN NULL is the same as CASE WHEN i = NULL...

    To check for NULLS you must use the searched CASE: CASE WHEN...

  • RE: Are the posted questions getting worse?

    rjohal-500813 (6/28/2010)


    Who'd have thought that the loss of a point would cause such collective bed-wetting

    The question reads "What will be the output of the following?" and none of the answers...

Viewing 15 posts - 7,726 through 7,740 (of 10,144 total)