Forum Replies Created

Viewing 15 posts - 1,351 through 1,365 (of 1,424 total)

  • Reply To: How to pass output parameter as input to another stored procedure

    tl;dr stands for "too long; didn't read" so your worries were well founded!  But seriously, what you posted worked and I'm very glad to have helped.  Readability is always a...

    Aus dem Paradies, das Cantor uns geschaffen, soll uns niemand vertreiben können

  • Reply To: SMB witness client error as critical

    This is outside my area but my 2 pennies: Witness Client and Witness Server are used to keep the cluster in sync.  The error appears to have triggered a retry...

    Aus dem Paradies, das Cantor uns geschaffen, soll uns niemand vertreiben können

  • Reply To: How to pass output parameter as input to another stored procedure

    The specific issue of: Must declare the scalar variable "@output".  This is because when you specify the output variable(s) in the execute statement the target variable needs to be on the...

    Aus dem Paradies, das Cantor uns geschaffen, soll uns niemand vertreiben können

  • Reply To: How to pass output parameter as input to another stored procedure

    Hey alright, now the code is tl;dr but it seems like you're on your way!

    #3, you're correct.  The proc output variable(s) can be of any type.  However, the RETURN type...

    Aus dem Paradies, das Cantor uns geschaffen, soll uns niemand vertreiben können

  • Reply To: How to pass output parameter as input to another stored procedure

    One reason the first proc is not functional is because the temporary table is out of scope.  Where does #ssrsresults get created?  If a temp table only has 1 '#'...

    Aus dem Paradies, das Cantor uns geschaffen, soll uns niemand vertreiben können

  • Reply To: insert with output clause

    N_Muller wrote:

    I can always change a select-insert into a merge. There's never going to be a "WHEN MATCHED". Must try to see if it solves the problem.

    Yep

    declare...

    Aus dem Paradies, das Cantor uns geschaffen, soll uns niemand vertreiben können

  • Reply To: How to replace placeholders in a string from an ordered list of column names

    This is done.  I couldn't find any satisfactory solution to placeholder replacement so the string formatting still happens in C#.  All of the text files and templates have been moved...

    Aus dem Paradies, das Cantor uns geschaffen, soll uns niemand vertreiben können

  • Reply To: Problem with simple stored procedure

    michael.leach2015 wrote:

    I think I see what you are saying about how many times the function could execute and the fact that I don't have a FROM clause.  Are you saying...

    Aus dem Paradies, das Cantor uns geschaffen, soll uns niemand vertreiben können

  • Reply To: Problem with simple stored procedure

    If you run it a million times.  In this case here the OP has no 'from' clause so it only executes once.  I actually did read your article a while...

    Aus dem Paradies, das Cantor uns geschaffen, soll uns niemand vertreiben können

  • Reply To: Problem with simple stored procedure

    If you're looking for something simple a scalar function could work.  The calculation requires no rows or columns.  If you know the function is accessed by query(s) in a proc...

    Aus dem Paradies, das Cantor uns geschaffen, soll uns niemand vertreiben können

  • Reply To: Help with Query Results and Collation

    Set operators work best when the tables are identical.  In this case there are different collations between tables.  Since "we're talking about thousands of columns across 100s of tables" it...

    Aus dem Paradies, das Cantor uns geschaffen, soll uns niemand vertreiben können

  • Reply To: Indirect reference to variable

    The procedure could be named whatever you wish.  "spFindExistingOrCreateNewProject" seems ok but a maybe little long...

    If the goal is to tighten/shorten the code then here are a few suggestions:

    1. Where...

    Aus dem Paradies, das Cantor uns geschaffen, soll uns niemand vertreiben können

  • Reply To: Indirect reference to variable

    Currently there are 2 procs:

    Proc 1 ("spNewProject") does 3 things: 1) returns all project records if all inputs are nulls, 2) if necessary creates new project and returns new record,...

    Aus dem Paradies, das Cantor uns geschaffen, soll uns niemand vertreiben können

  • Reply To: Indirect reference to variable

    Are you certain so much individual error checking is necessary?  Sometimes it can be less wordy to "jfdi", or just f---ing do it.  Whatever you're trying to do once all...

    Aus dem Paradies, das Cantor uns geschaffen, soll uns niemand vertreiben können

  • Reply To: Linked Teradata Server Query Problems

    Hi there,

    "The OLE DB provider "MSDASQL" for linked server..."  Are you using the “OLE DB Provider for ODBC Drivers”?  MSDASQL is a very old interface, it's either deprecated or on...

    Aus dem Paradies, das Cantor uns geschaffen, soll uns niemand vertreiben können

Viewing 15 posts - 1,351 through 1,365 (of 1,424 total)