Forum Replies Created

Viewing 15 posts - 271 through 285 (of 761 total)

  • RE: Search with 80% accuracy

    Hi, Welcome To SSC.

    It is never supposed to be this simple but won't the following get you the 80% accurate Search you need??

    Select Top 1 * From <TableName>

    Where FirstName LIKE...

  • RE: Record Matching in FIFO Basic in Stock data

    Very nice solution Chris.

    Sorry for my last post. I had missed(not understood, actually) the "B--Buy, S--Sell" part. That is why I was asking for a Transactions Table. My bad.

  • RE: Hide zero quantities in sql query

    ann 31613 (6/18/2012)


    Hi Vijay

    Managed to solve the issue. Thank you.

    You're very welcome.

    I'm glad it worked out for you.

  • RE: Sum the most recent record for each day

    dwain.c (6/18/2012)


    vinu512 (6/18/2012)


    You can do it like this as well:

    --Creating Temporary Table

    CREATE TABLE #Test

    (

    DateTimeStamp datetime,

    Value int

    )

    --Inserting Sample Data

    INSERT INTO #Test SELECT '2012-06-15 16:00:00.000',4

    INSERT INTO #Test SELECT '2012-06-15 2:05:00.000',5

    INSERT INTO...

  • RE: need to replace

    dwain.c (6/18/2012)


    vinu512 (6/18/2012)


    harri.reddy (6/17/2012)


    alright,consider this

    i have 1 variable

    declare @temp1 nvarchar(50)

    set @temp1 = 'P=70'

    now in 1 column i need p and in another i need 70 ,from @temp1

    so i need function...

  • RE: Record Matching in FIFO Basic in Stock data

    How is SQL Server supposed to know that you have a FIFO business logic in mind.

    Do you have a transactions table where you record the Transactions, quantity sold/bought, Date of...

  • RE: need to replace

    harri.reddy (6/17/2012)


    alright,consider this

    i have 1 variable

    declare @temp1 nvarchar(50)

    set @temp1 = 'P=70'

    now in 1 column i need p and in another i need 70 ,from @temp1

    so i need function who can...

  • RE: Sum the most recent record for each day

    You can do it like this as well:

    --Creating Temporary Table

    CREATE TABLE #Test

    (

    DateTimeStamp datetime,

    Value int

    )

    --Inserting Sample Data

    INSERT INTO #Test SELECT '2012-06-15 16:00:00.000',4

    INSERT INTO #Test SELECT '2012-06-15 2:05:00.000',5

    INSERT INTO #Test SELECT...

  • RE: Hide zero quantities in sql query

    ann 31613 (6/17/2012)


    Hi All,

    I have written a html query (please see below) and would like the query to hide On hand Qty which are zero. Can someone help me?...

  • RE: sql server

    You can do it as follows, but the results would vary according to the Order in the chosen Execution Plan.

    The results may not be universal in this case as there...

  • RE: Transferring Data from one table to another

    Lucasprss (6/17/2012)


    I would like to know what is the syntax to move existing data from one table to another, for example tblAsset which contains Policy No (INT), PolicyStart(DateTime) and PolicyEnd(DateTime)...

  • RE: Get List of Tables which have acquired locks

    Thanks a tonne Anthony.

    I'll do some reading and understanding and lets see where I can get with it.

    Thanks again,

  • RE: How to query results in debit and credit column

    The Sql Server Gurus are really fast here at SSC. 😀

    By the time I read the new thread, it was all done and dusted. 😛

    Nice work Lynn and Dwain.

  • RE: Unpivoting Data

    ChrisM@Work (6/15/2012)


    anthony.green (6/15/2012)


    Thanks guys, much appreciated. Was racking the brain yesterday on that and for the life of me couldnt get unpivot working.

    I like the idea of the values...

  • RE: Case With Group by Row Values into Column

    farooq.hbs (6/15/2012)


    Thanks Buddy...

    I got the Solution

    You're welcome.

    Could you please post the solution so that other visitors to this thread(including me and Lynn) could know what was wrong and how you...

Viewing 15 posts - 271 through 285 (of 761 total)