Forum Replies Created

Viewing 15 posts - 5,416 through 5,430 (of 7,636 total)

  • RE: Join three tables and

    Lynn Pettis (9/30/2008)


    Looking back at the sample data provided, nope. Need to have an outer join between table2 and table3.

    Sorry, Lynn, I was just talking about the transformation from...

  • RE: Complex queries in a VB-based CLR

    kent.kester (9/30/2008)


    The part that clinched it for me was when I started thinking about injection. I know it's usually considered a web-style attack but it could just as easily...

  • RE: Execute a stored procedure inside a user defined function

    Yeah, if I do have to do this, I would much rather use OPENQUERY than xp_CmdShell.

  • RE: Stored Procedure Ownership Chaining

    Have you set your Web database to be TRUSTED?

  • RE: Trying to join to xp_fileexist

    I just noticed:

    CREATE FUNCTION dbo.file_exists (@filenam as varchar(max))

    RETURNS @tabexist TABLE (fileexist int,fileisdir int,parentexist int)

    AS

    BEGIN

    Declare @Exists int

    Set @Exists = 0

    --INSERT INTO @tabexist EXEC master..xp_fileexist @filenam

    EXEC master..xp_fileexist @filenam, @Exists OUTPUT

    Insert into...

  • RE: Trying to join to xp_fileexist

    Heh. Now this is one of the few things that SQLCLR is good for. It is fairly easy to write a SQLCLR Function with EXTERNAL_ACCESS rights to do...

  • RE: Join three tables and

    Jeffrey Williams (9/30/2008)


    tbeadle (9/29/2008)


    As for the other paragraphs - basically, you cannot have the following:

    SELECT ...

    FROM table1

    LEFT JOIN table2 ON table2.fkey = table1.key

    ...

  • RE: Is this article correct? Temp Tables vs. Table Variables in SQL Server 2005

    As far as I know, this article is correct (not entirely sure about #2, I think that may only be partialy true). Also, it misses another one: Temp Tables...

  • RE: Select *

    Maybe you could write a Logon trigger that does a SET ROWCOUNT 1000? 😀

    Of course there are a whole lot of potential problems with that...

  • RE: Execute a stored procedure inside a user defined function

    Matt Miller (9/30/2008)


    And - considering this is getting around a prohibition from the devs - I wouldn't be incredibly surprised if this loophole does get closed at some point.

    Aye, there's...

  • RE: Execute a stored procedure inside a user defined function

    Cool. Have you tried it yet? (Its not that I doubt you :), its just that I have been surprised more than once by how thorough they were in...

  • RE: Duplicate records

    dale_keller (9/30/2008)[hrI just wish SQL Server Management Studio would display the record in question when it comes back with the duplicate error message.

    Yeah, but what if there were a million...

  • RE: Duplicate records

    Here are the queries to find the dupes:

    --Find duplicates between source and target

    Select T1.PARTY_ID, T1.Client_ID

    From PARTY AS T1

    Inner Join [PSS_STAGING].[dbo].[party] O1

    ON O1.Party_ID = T1.Party_ID

    --Find duplicates in source:

    Select...

  • RE: Execute a stored procedure inside a user defined function

    Matt Miller (9/30/2008)


    If you allow for using OPENQUERY, it gets a whole lot easier....

    That would be better, but I am not actually sure that OPENQUERY can do it Matt. ...

  • RE: Execute a stored procedure inside a user defined function

    ND (9/17/2006)


    one way is to use xp_cmdshell to call a batch file where the batch file contains the exec proc statement.

    First of all, that is not "one way", it...

Viewing 15 posts - 5,416 through 5,430 (of 7,636 total)