Forum Replies Created

Viewing 15 posts - 2,941 through 2,955 (of 8,761 total)

  • RE: Remove decimal from varchar field

    Quick suggestion

    😎

    USE TEEST;

    GO

    SET NOCOUNT ON;

    ;WITH SAMPLE_DATA(NUMBERS) AS

    ( SELECT CONVERT(VARCHAR(7),X.NUMBERS,0)

    FROM ( VALUES

    ('1.22345')

    ...

  • RE: simple question

    scottlackey2001 (11/3/2016)


    is there a way to loop through rows without using a cursor? I can select my rows into a temp table and all, but need to loop through...

  • RE: simple question

    scottlackey2001 (11/3/2016)


    I've got a DECLARE CURSOR and I wish to loop through and process rows that meet certain criteria. I want to use a WHILE loop to process such...

  • RE: Insert XML into SQL Server table

    User7766 (11/3/2016)


    Added this line to make it work, somewhere i'm missing the casting

    ,MessageBody = CAST(MSG.DATA.query('(.)') AS nvarchar(MAX))

    Thanks...

  • RE: Username increment by 1 if already exists in table

    Here is a suggestion, should be enough to get you passed this hurdle

    😎

    USE TEEST;

    GO

    SET NOCOUNT ON;

    IF OBJECT_ID(N'tempdb..#Employee') IS NOT NULL DROP TABLE #Employee;

    Create table #Employee

    (

    ID int identity (1,1) ,

    FirstName...

  • RE: Insert XML into SQL Server table

    User7766 (11/3/2016)


    Hi,

    Thanks for the query!

    I'm able to select all the columns from XML, But when i try to run the insert query getting below error.

    Implicit conversion from data type xml...

  • RE: Insert XML into SQL Server table

    DesNorton (11/3/2016)


    Shredding xml is not exactly the best perfprming operation in SQL. Rather get the UI to shred the XML and pass you a TVP (table valued parameter).

    If you...

  • RE: Insert XML into SQL Server table

    The XML data type in SQL Server can easily handle multiple root nodes which is somewhat an exception to the rule, my concern was that normally this would break or...

  • RE: Insert XML into SQL Server table

    This XML is not well formed as there are multiple root nodes, is this the actual XML?

    😎

    The CTE in your code will only retrieve values from the Header part of...

  • RE: SSMS 2016 slow connection (Windows 10)

    matej_grabnar (11/2/2016)


    After upgrading from Windows 7 to Windows 10 - and after some updates of windows a very slow connection (10 - 20s) to SQL server accrued.

    Queries are executing...

  • RE: Stored Procedure using Sql server 2012

    poornima.s_pdi (11/1/2016)


    Hi Eirikur Eiriksson,

    Thank you very much.

    The Stored Procedure worked now.

    Interested in learning these stored procedure and this forum is really helpful.

    Tks for your immediate reply.:-)

    Regards,

    Poornima

    You are very welcome.

    😎

  • RE: Easy way to search for a string any where within XML column?

    Locating a string pattern within a string is straight forward, regardless of whether the string is an XML or not, here is a quick example of a search in an...

  • RE: Speeding Up Delete's on Large Databases

    In most cases, we will see up to 2 times better performance when applying this method, more commonly the difference is greater. Here is an example, results speak for themselves...

  • RE: SSIS Excel import error

    spidey73 (11/1/2016)


    It must have something to do with authentication/privileges on the Server A on which the SSIS package is hosted and executed by a SQL job.

    Because when I elevate the...

Viewing 15 posts - 2,941 through 2,955 (of 8,761 total)