Forum Replies Created

Viewing 15 posts - 1 through 15 (of 17 total)

  • Reply To: Set permisson user allow connect with application, don't allow connect with ssms

    Grant Fritchey wrote:

    If a user knows the right login and the right location to use, they can connect with any tool at all.

    yeah, that why i need for help. With simple...

    • This reply was modified 1 year, 10 months ago by  mrsiro.
    • This reply was modified 1 year, 10 months ago by  mrsiro.
  • Reply To: Stuff xml path query

    hello, can you reconmend some way to solved that ?

    If i split proc, that is nightmare about number of proc and manage them, one proc one action, usally a table...

    • This reply was modified 1 year, 10 months ago by  mrsiro.
  • Reply To: Stuff xml path query

    hello, it's relation to myoriginal question here, because i have some test with stuff query in sql 2008.

    CREATE PROCEDURE test
    @kind NVARCHAR(10), @id NVARCHAR(10),
    @startday date, @endday date
    AS
    BEGIN
    SET NOCOUNT...

    • This reply was modified 1 year, 10 months ago by  mrsiro.
    • This reply was modified 1 year, 10 months ago by  mrsiro.
    • This reply was modified 1 year, 10 months ago by  mrsiro.
    • This reply was modified 1 year, 10 months ago by  mrsiro.
    • This reply was modified 1 year, 10 months ago by  mrsiro.
  • Reply To: Stuff xml path query

    hello guys, is it ok if i write many jobs in a storeprocedure ? Like this:

    ALTER PROCEDURE test
    @kind NVARCHAR(10)
    AS
    BEGIN
    SET NOCOUNT ON;
    IF @kind = '1'
    BEGIN
    SELECT * FROM dbo.tbl1
    END

    IF...

    • This reply was modified 1 year, 10 months ago by  mrsiro.
  • Reply To: Stuff xml path query

    hello, my storeproc, need to change for 2017 ?

    SET XACT_ABORT ON
    BEGIN TRAN
    BEGIN TRY
    ...
  • Reply To: Stuff xml path query

    hello, guys, i have some test with string_agg in sqlserver2017. It's seem to be best solution ever. With xml path  quey run 30s, string_agg run 2s, oh my god. Perfect.

    Now,...

    • This reply was modified 1 year, 10 months ago by  mrsiro.
  • Reply To: Stuff xml path query

    yes, i decide pivot in sql query. Now, problem is dynamic query as my post #3790843. The infomation in your website is very detailed

    , but it's seen very complicated for...

  • Reply To: Stuff xml path query

    thank erland, many loop in code, it's not good for performance, and i need write some code use dictonary and split to get finally result.

    I think i dont need to...

    • This reply was modified 1 year, 10 months ago by  mrsiro.
  • Reply To: Stuff xml path query

    hello, if you dont mind, can you recommend some way to do it client side, i used c#.net.

     

  • Reply To: Stuff xml path query

    hello, if you have better way or query please tell me. And I worry about sql injection with EXECUTE(@sql).

  • Reply To: Stuff xml path query

    Hello guys, can i custom number of column in pivot that is not need to be add permission "select" for user.

    I have code:

    DECLARE @column NVARCHAR(MAX)
    SELECT @column =...

    • This reply was modified 1 year, 10 months ago by  mrsiro.
    • This reply was modified 1 year, 10 months ago by  mrsiro.
  • Reply To: Stuff xml path query

    hello guys,

    With Mr.Brian code,  run on temp data is so good. But i run code on real database table which have 100k record, it's bad horribly performace, too slow. Please...

    • This reply was modified 1 year, 10 months ago by  mrsiro.
  • Reply To: Stuff xml path query

    thanks Erland and Mr.Brian, i run yours code with display estimated execution plan, Erland code with 98%, Mr.Brian with 2%. Why it so different performace.

    Anyway, both code is give me...

  • Reply To: Sum query

    yes, next question is #3763756

    add column price in table1, column kind in table2.

    • This reply was modified 2 years, 1 month ago by  mrsiro.
  • Reply To: Sum query

    thanks guys,

    Next question:

    how to get result like yellow

    • This reply was modified 2 years, 1 month ago by  mrsiro.

Viewing 15 posts - 1 through 15 (of 17 total)