Viewing 15 posts - 151 through 165 (of 482 total)
Exception calling "SetOwner" with "1" argument(s): "Set owner failed for Database DB"
+ $db.SetOwner("[Domain\User]")
October 23, 2014 at 10:34 am
If memory serves -- and it's been a loooong time -- the detach-attach functionality only arrived with SQL 7.
So you're stuck with Restore Database.
First, create an new, empty db.
I think...
September 17, 2014 at 7:29 am
Here's a slightly different approach: start with the the matching groups, so you don't process users that aren't members of any of those groups.
Then count the groups for each of...
September 17, 2014 at 7:21 am
Hi Erland,
They only need to be able to create a new schedule for an existing job. Essentially, I want them to be able to call a stored proc at the...
July 22, 2014 at 6:44 am
Hi Chris,
Yep, that was my conclusion too. However, since query fails, I couldn't see the execution plan. Unless there's a way?
And, the iTVF would probably neatly obviate the original...
July 10, 2014 at 7:35 am
So it turns out that in the 2 failing scenarios, the function is going through the full table before applying the WHERE clause, and failing on a row where first...
July 9, 2014 at 5:38 am
FWIW, Thinking it might have been generating an n x 1 CROSS JOIN, I moved the JOIN dbo.lookup out of the select statement in the function, since it wasn't actually...
July 8, 2014 at 9:56 am
Now, when I change the definition of that column in the table function to allow NULLs, it works!
And the last 2 versions which previously threw the error do NOT...
July 8, 2014 at 9:45 am
Once again, that's not the problem: call that function directly with the single value -- and there is only one single value in this example -- and it works just...
July 8, 2014 at 8:45 am
That's not the problem, HanShi. The first name and last names are not null in this instance, and if you look at the original post, you'll note the code works...
July 8, 2014 at 8:12 am
Function code below.
Specifically, the error thrown is:
Msg 515, Level 16, State 2, Line 1
Cannot insert the value NULL into column 'Clientname', table '@tRS'; column does not allow nulls. INSERT fails.
The...
July 8, 2014 at 8:03 am
Lol! Fail as in throws an error. (But for my users, it's the End. Of. The. World.)
The cross apply returns a table, but the table has the columns defined not...
July 8, 2014 at 7:55 am
WHILE: Agreed. However, this sproc is called for Inserts and updates an average of 10x/day, so the perf hit is probably not noticeable.
As for the cursor, there are 2 related...
June 26, 2014 at 9:57 am
Sean, I'd be happy to hear any suggestions re: perf improvement.
June 26, 2014 at 9:36 am
The value is passed in the call to the sproc:
DECLARE @nKeyword_IdVarINTEGER = 120375
DECLARE @nErrorVarINTEGER = 0
BEGIN TRAN New_Tran
EXECUTE @nErrorVar = dbo.wadw_keywords
@cActionArg = 'D',
@nKeyword_IdArg = @nKeyword_IdVar OUTPUT
So it was evaluating to...
June 26, 2014 at 9:23 am
Viewing 15 posts - 151 through 165 (of 482 total)