Log in
::
Register
::
Not logged in
Home
Tags
Articles
Editorials
Stairways
Forums
Scripts
Videos
Blogs
QotD
Books
Ask SSC
SQL Jobs
Training
Authors
About us
Contact us
Newsletters
Write for us
Recent Posts
Recent Posts
Popular Topics
Popular Topics
Home
Search
Members
Calendar
Who's On
Home
»
SQL Server 2005
»
CLR Integration and Programming.
»
Creating assembly
16 posts, Page 1 of 2
1
2
»»
Creating assembly
Rate Topic
Display Mode
Topic Options
Author
Message
J Sitz
J Sitz
Posted Friday, March 07, 2008 3:08 PM
Grasshopper
Group: General Forum Members
Last Login: Tuesday, April 29, 2008 8:34 AM
Points: 18,
Visits: 28
Last week I had created and added a new CLR assembly to a database. I stopped working on it to work on another project, and today I could no longer run the functions from the assembly. I kept getting the following error:
Msg 6533, Level 16, State 48, Line 1
AppDomain .dbo[ddl].59 was unloaded by escalation policy to ensure the consistency of your application. Out of memory happened while accessing a critical resource.
I tried deleting the assembly and was going to try recreating the assembly. Now when I run the Create Assembly statement I get the same error. I tried creating on another database and it did not work. I tried creating an empty assembly just to see if it could have been something with my assembly, but I couldn't even do that.
What I don't understand is why last week I was able to create the assembly on the database, and add the functions to the database, and now this week it is broken. Could it have been some update that occurred to our server? Is there any options that I need to check? Any help would be greatly appreciated. Thanks in advance!
Post #466170
Jeff Moden
Jeff Moden
Posted Friday, March 07, 2008 3:14 PM
SSC-Dedicated
Group: General Forum Members
Last Login: Yesterday @ 9:57 PM
Points: 32,893,
Visits: 26,771
Heh... it's the SQL gods telling you that you should solve the problems in T-SQL instead of writing a CLR :D
--Jeff Moden
"
RBAR
is pronounced "ree-bar" and is a "Modenism" for "
R
ow-
B
y-
A
gonizing-
R
ow".
First step towards the paradigm shift of writing Set Based code:
Stop thinking about what you want to do to a row... think, instead, of what you want to do to a column."
For better, quicker answers on T-SQL questions, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
Post #466175
Matt Miller (#4)
Matt Miller (#4)
Posted Friday, March 07, 2008 3:21 PM
SSCertifiable
Group: General Forum Members
Last Login: Friday, May 17, 2013 1:56 PM
Points: 6,997,
Visits: 13,941
What's the memory situation of that server? Sounds to me like a leak not releasing resources.
Have you had a chance to reboot it recently to see if you can use this on "clean" resources?
Also - there's a hotifx out that has that message as an exact decription....It's over here:
http://support.microsoft.com/kb/928083
----------------------------------------------------------------------------------
Your lack of planning does not constitute an emergency on my part...unless you're my manager...or a director and above...or a really loud-spoken end-user..All right - what was my emergency again?
Post #466181
J Sitz
J Sitz
Posted Friday, March 07, 2008 4:08 PM
Grasshopper
Group: General Forum Members
Last Login: Tuesday, April 29, 2008 8:34 AM
Points: 18,
Visits: 28
Thanks for the quick replies!
When you say it "Sounds to me like a leak not releasing resources.", do you mean from the assembly that I created? I have this installed and runs fine on my local. This is not actually in production yet. I just installed and created all the functions on the production database. I was creating a view to use the assembly and that is when I received the error. There is really no resources that I need to release. The assembly (dll) just calculates the companies holidays. I'll try rebooting the server this weekend when nobody is using it.
Post #466201
Jeff Moden
Jeff Moden
Posted Friday, March 07, 2008 4:13 PM
SSC-Dedicated
Group: General Forum Members
Last Login: Yesterday @ 9:57 PM
Points: 32,893,
Visits: 26,771
The assembly (dll) just calculates the companies holidays.
Curious... did you know that a T-SQL function will likely run just as fast here and a properly formed Calendar table will out stripe both? And neither will cause the problems you're currently experiencing?
--Jeff Moden
"
RBAR
is pronounced "ree-bar" and is a "Modenism" for "
R
ow-
B
y-
A
gonizing-
R
ow".
First step towards the paradigm shift of writing Set Based code:
Stop thinking about what you want to do to a row... think, instead, of what you want to do to a column."
For better, quicker answers on T-SQL questions, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
Post #466202
J Sitz
J Sitz
Posted Sunday, March 09, 2008 7:35 PM
Grasshopper
Group: General Forum Members
Last Login: Tuesday, April 29, 2008 8:34 AM
Points: 18,
Visits: 28
The function automatically calculates the holiday's such as Easter, Memorial Day, etc.
Post #466449
Jeff Moden
Jeff Moden
Posted Sunday, March 09, 2008 9:50 PM
SSC-Dedicated
Group: General Forum Members
Last Login: Yesterday @ 9:57 PM
Points: 32,893,
Visits: 26,771
Are you happy with the performance?
--Jeff Moden
"
RBAR
is pronounced "ree-bar" and is a "Modenism" for "
R
ow-
B
y-
A
gonizing-
R
ow".
First step towards the paradigm shift of writing Set Based code:
Stop thinking about what you want to do to a row... think, instead, of what you want to do to a column."
For better, quicker answers on T-SQL questions, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
Post #466465
J Sitz
J Sitz
Posted Monday, March 10, 2008 7:05 AM
Grasshopper
Group: General Forum Members
Last Login: Tuesday, April 29, 2008 8:34 AM
Points: 18,
Visits: 28
I was when it was working. There really wasn't a noticeable slow down. But there are only approximately 300-500 records at any given time.
Post #466645
J Sitz
J Sitz
Posted Monday, March 10, 2008 8:07 AM
Grasshopper
Group: General Forum Members
Last Login: Tuesday, April 29, 2008 8:34 AM
Points: 18,
Visits: 28
Matt,
Rebooting the server fixed it. How can I test for a memory leak on the server? This was the first assembly on the server, but it was not in production. I don't see how it could cause a memory leak. There are no resources that need to be disposed. It just calculates dates.
Post #466684
Jeff Moden
Jeff Moden
Posted Monday, March 10, 2008 8:12 PM
SSC-Dedicated
Group: General Forum Members
Last Login: Yesterday @ 9:57 PM
Points: 32,893,
Visits: 26,771
Would be a heck of a lot faster if you used a holiday table or, better yet, a calendar table.
--Jeff Moden
"
RBAR
is pronounced "ree-bar" and is a "Modenism" for "
R
ow-
B
y-
A
gonizing-
R
ow".
First step towards the paradigm shift of writing Set Based code:
Stop thinking about what you want to do to a row... think, instead, of what you want to do to a column."
For better, quicker answers on T-SQL questions, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
Post #467096
« Prev Topic
|
Next Topic »
16 posts, Page 1 of 2
1
2
»»
Permissions
You
cannot
post new topics.
You
cannot
post topic replies.
You
cannot
post new polls.
You
cannot
post replies to polls.
You
cannot
edit your own topics.
You
cannot
delete your own topics.
You
cannot
edit other topics.
You
cannot
delete other topics.
You
cannot
edit your own posts.
You
cannot
edit other posts.
You
cannot
delete your own posts.
You
cannot
delete other posts.
You
cannot
post events.
You
cannot
edit your own events.
You
cannot
edit other events.
You
cannot
delete your own events.
You
cannot
delete other events.
You
cannot
send private messages.
You
cannot
send emails.
You
may
read topics.
You
cannot
rate topics.
You
cannot
vote within polls.
You
cannot
upload attachments.
You
may
download attachments.
You
cannot
post HTML code.
You
cannot
edit HTML code.
You
cannot
post IFCode.
You
cannot
post JavaScript.
You
cannot
post EmotIcons.
You
cannot
post or upload images.
Copyright © 2002-2013 Simple Talk Publishing. All Rights Reserved.
Privacy Policy.
Terms of Use.
Report Abuse.