Forum Replies Created

Viewing 15 posts - 931 through 945 (of 2,894 total)

  • RE: Column Data Consolidation

    ...

    Apologies for my lack of information i am new to SQL and to this forum.

    The following will get you started receiving relevant and fast responses on this forum:

    http://www.sqlservercentral.com/articles/Best+Practices/61537/

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: 'Select Into' logs

    ...if I change the Recovery Model to Bulk-Logged, will that prevent the log files growing substantially during the process, or would I be better off if I script an export...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Column Data Consolidation

    Google the following:

    Concatenate FOR XML PATH

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Is it "better" to specify the definition of a temporary table, or just define it on the fly?

    Evil Kraig F (10/30/2012)


    ...

    CREATE TABLE #Tmp CREATE INDEX idx1 INSERT INTO #tmp SELECT

    runs about 1.5x - 2x faster (depending on the index) as

    SELECT INTO #tmp CREATE INDEX idx1

    ...

    Could you...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Pivoting Help

    BTW. Formatting your query nice, improves its readability and therefore its maintainability:

    SELECT vcEmployeeUniqueID

    ,vcLastName

    ...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Pivoting Help

    You are almost there!

    just use MAX instead of COUNT 🙂

    also you don't need to sub-query select of all columns from #X:

    ...

    FROM #X1 p

    PIVOT ...

    will do just fine!

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Pivoting Help

    Looks like homework to me.

    Have you tried using PIVOT. Where are you so far?

    We can help you to learn and resolve issues instead of just providing straight solutions,...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Pivoting Help

    No need in duplicating your posts!

    http://www.sqlservercentral.com/Forums/Topic1384158-392-1.aspx

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Stored Procedure

    edward_hall76 (11/13/2012)


    ok. where I work not all people know how to write tsql code and if they mess up the tsql they do not know how to fix it is...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: Stored Procedure

    edward_hall76 (11/13/2012)


    I have a stored procedure and want to know after I run it is there away to get it to reopen with out having to right click on it...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: WHERE Filter

    To pass values as a comma separated string, you need to concatenate them into one comma separated string and pass it.

    To use it in you procedure, you can use "IN"...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: WHERE Filter

    2Tall (11/13/2012)


    Hi to all. I haven't posted for a while and it is now time to wear my sql cap again 🙂

    I have a query which in brief has the...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: SET STATISTICS TIME ON

    ben.brugman (11/13/2012)


    How to save the results from "SET STATISTICS TIME ON" in table format?

    Ben Brugman

    In exactly same way as result of PRINT - it is impossible in T-SQL as it's...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: rounding

    SELECT CEILING(10.434 * 100)/100

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

  • RE: CREATING A COLUMN TO RETURN THE MAX VALUE FOR EACH GROUP WITHIN A SUBQUERY

    That is what could easily win "Query From Hell" competition...

    It's "War and Peace" of the queries!

    Does it run at all (even without grouping)?

    Before trying to help or resolve any problem...

    _____________________________________________
    "The only true wisdom is in knowing you know nothing"
    "O skol'ko nam otkrytiy chudnyh prevnosit microsofta duh!":-D
    (So many miracle inventions provided by MS to us...)

    How to post your question to get the best and quick help[/url]

Viewing 15 posts - 931 through 945 (of 2,894 total)