Forum Replies Created

Viewing 15 posts - 6,001 through 6,015 (of 15,381 total)

  • RE: insert twice seems to pick up new id

    nick 91670 (1/8/2014)


    I have a SP that is creating two new records that are copies of the original (so I get three near identical records)

    the following two lines (simplified) are...

  • RE: DateAdd from Max DateValue Column

    Something like this?

    declare @EndDate datetime = '2013-12-15'

    select dateadd(yy, datediff(yy, 0, @EndDate), 0) -- Beginning of this year

    This came from Lynn's blog post with lots of common...

  • RE: Transform data into column

    mzsleo85 (1/8/2014)


    Thank You Sean for your nice suggestions and help.

    The solution which you provided me is working to me. (Thanks a lot)

    I ll keep in mind all the points that...

  • RE: COUNT

    sharonsql2013 (1/8/2014)


    Yes so I am counting RoundTables in ('1', N/A') AND IsVideo in ('1', 'N/A').

    and then need to do an and between these to counts.

    Should I separately count and then...

  • RE: Ensuring stored procedure actually runs with permissions of the caller

    When a user has rights to execute a stored procedure it will be assumed that they can do whatever the procedure code does. It does not check privileges for each...

  • RE: COUNT

    sharonsql2013 (1/8/2014)


    This is what I need to actually count.

    COUNT(*)round

    from CTE1

    where

    ( (Cte1.Roundtables = '1' OR Cte1.Roundtables= 'N/A')

    AND

    (CTE1.IsVideo = '1' OR CTE1.IsVideo = 'N/A'))

    SO, I am trying...

  • RE: Transform data into column

    Hi and welcome to the forums. It is considered best practice to post ddl and sample data so that we can work directly on your problem. Since this is your...

  • RE: Change code in all views

    Tara-1044200 (1/8/2014)


    I have more than 100 views in a database and i would like to change the from clause for all of them in one attempt, is there a way...

  • RE: SQL Help needed...

    Is there any chance you can normalize this data instead of fighting what looks like a text file all the time?

  • RE: SQL Help needed...

    Now I see what you are trying to do. Does something like this work?

    select WorkItemId

    , replace(SUBSTRING(WorkItemDescription, CHARINDEX('Related Work Items', WorkItemDescription) + 20, LEN(WorkItemDescription)), ';', '')

    from @tblRawData

  • RE: SQL Help needed...

    satishchandra (1/7/2014)


    Have the following data in the table.

    Declare @tblRawData as table

    (

    WorkItemId int,

    WorkItemDescription varchar(500)

    )

    insert into @tblRawData select 10110, 'Parallel Work Items: 10111, 10112; Related Work Items: 10113, 10114;'

    insert into @tblRawData select...

  • RE: Updating 2 databases at the exact same time

    Jeff Moden (1/7/2014)


    Oooooo.... the classic MK I. I haven't seen one of those in a long time. It was one of my favorites even though the velocity and...

  • RE: Substring and trimming

    You can just use replace around what you already have.

    replace(substring(f.frag_pct, charindex('Fragmented', f.frag_pct, 1) + 12, 2), '%', '') AS file_fragpct

  • RE: Exercise Q from 70-461 Training Book

    rho_pooka (1/7/2014)


    Thanks for such prompt replies all!

    Koen, isn't the query that I had written a test just like your second example?

    Struggling with this one, thanks again for help.

    No you have...

  • RE: Not finding 70-463 ebook for downloads

    I can tell you that nobody around here is going to provide with a way to download a pirated copy of a book. Here is a link to the book...

Viewing 15 posts - 6,001 through 6,015 (of 15,381 total)