Forum Replies Created

Viewing 15 posts - 946 through 960 (of 2,917 total)

  • Reply To: How to split Xml columns or Json into records

    I don't see why you can't do this.  You already have it started, just need to expand on it to capture each and every element in the XML.  Something along...

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

  • Reply To: Database Integrity Issues

    It might not hurt to reach out to Vormetric as well.  It is a paid tool, so might as well get their support.

    From my experience, once corruption happens, unless I...

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

  • Reply To: how to get quantity from yesterday 6pm till today 6pm

    I think your problem is with your WHEN statements.  Let us look at the first one:

    WHEN CAST(CONCAT(CREATE_DATE, ' ', CREATE_TIME) AS DATETIME) BETWEEN
    dateadd(hh, 15, dateadd(dd, -1, convert(datetime,...

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

  • Reply To: Speeding up Query

    I agree... there isn't much to go on.

    Having an execution plan and DDL would definitely help us help you.  Without that, it is impossible to know what would help.  Adding...

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

  • Reply To: SQL - SUBSTRING combined with CHARINDEX not returning desired results.

    An alternate solution that doesn't rely on the DelimitedSplit8K:

    WITH [SampleData2] ([PERSONNUM], [ORGPATHTXT])
    AS
    (
    SELECT
    231089
    , './Company/20-00001/120---30-00006/40-00506/50-99506/60-29145/97455001/0097455001/Fire-Grill'
    UNION ALL
    SELECT
    121564
    , './Company/20-00001/120---30-00006/40-00073/50-00075/60-26275/68990001/0068990001/Location3/Burger-Cook'
    UNION ALL
    SELECT
    999998
    , './Company/20-00001/120---30-00006/40-00073/50-00075/60-26275/77990993/0077990993/Location6/Food-Worker'
    )
    , [sampledata3] ([PERSONNUM], [ORGPATHTXT], [NoLocation], [ContainsLocation])
    AS
    (
    SELECT
    [SampleData2].[PERSONNUM]
    , [SampleData2].[ORGPATHTXT]
    , REPLACE( [SampleData2].[ORGPATHTXT]
    ,...

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

  • Reply To: Got more questions concerning using RStudio and how to put "whatever" into Git

    Oh I completely agree.  you should clone to your local disk, not a network share.  And a good way to prove to them that is the way to go -...

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

  • Reply To: Got more questions concerning using RStudio and how to put "whatever" into Git

    I'm not that familiar with RStudio, but I know git and their idea of versioning by folder is something unneeded in git.

    In git, the way I would handle it is...

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

  • Reply To: MSSQL Table Variable Identification

    I actually thought the same thing as homebrew01 - when the query completes, the table should go away.  The exception is with temporary tables, which would go away when the...

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

  • Reply To: MSSQL Table Variable Identification

    I did find one way to do this, but it relies on the query still being in the plan cache and is not a very "automated" approach and has potential...

    • This reply was modified 4 years, 9 months ago by Mr. Brian Gale. Reason: Updated for more accurate lookups

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

  • Reply To: MSSQL Table Variable Identification

    I was actually just experimenting with this and I am mistaken on how you would find it.

    Turns out the plan cache doesn't map this up either... I am going to...

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

  • Reply To: MSSQL Table Variable Identification

    Are the table names consistent?  What I mean is are they always the same 8 hex characters?  If so, then you could use a tool like SQL Search (RedGate free...

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

  • Reply To: ASPNETDB - Lock Out SharePoint Accounts not logged on in a long time

    I think this is possible but messy and mildly risky.  Mildly risky as you would need to use dynamic SQL and there is a chance you could lock out an...

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

  • Reply To: SSRS Switch with an Or?

    Going back to the IIF approach, could you not do something like:

    =IIf(Parameter!ProviderID.Value = 1, 'A,B', 
    IIf(Parameter!ProviderID.Value = 2, 'B,C',
    IIf(Parameter!ProviderID.Value =...

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

  • Reply To: Ozar's SP_BlitzCache has bad news

    That is just telling you that you need more memory to store query plans OR you need fewer unique query plans running against the instance.  With the most of your...

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

  • Reply To: HOW DO I KNOW THE SQL SERVER WAS BUSY FOR A PARTICULAR TIME

    I just wanted to second Ant-Green's statement about buying a tool.  SQL Monitoring tools are a must for any SQL instance you care about.

    And his statement about checking the logs...

    The above is all just my opinion on what you should do. 
    As with all advice you find on a random internet forum - you shouldn't blindly follow it.  Always test on a test server to see if there is negative side effects before making changes to live!
    I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.

Viewing 15 posts - 946 through 960 (of 2,917 total)