Showing posts with label reading. Show all posts
Showing posts with label reading. Show all posts

Wednesday, March 21, 2012

Is it possible to create a UDF from a .NET 2.0 assembly that uses dllimport to call unmanaged co

I have been reading up on everything I can find on this subject and I am not clear if this is allowed within the SQL Server 2005 CLR. My function calls work within a Windows form project, but don't run when invoked from a SQL function. I don't get any errors or warnings when creating the assembly and functions within SQL Server, but when running via a select statement, the spid just hangs and I have to stop & restart the service to kill the process. I have been investigating the security settings for this assembly, but I think I have that covered via the RunTime Security Policy settings in the .NET Framework 2.0 Configuration tool.

Any insights, knowledge, or thoughts would be greatly appreciated.

Barry

Hi Barry,

Calling into a CLR function which in turn p-invokes into unmanaged code should work without issues, although we would usually recommend against this if you can avoid it, as it would require the assembly being registered as UNSAFE.

What is the unmanaged code doing? Is it possible to have a look at your SQL function?

Thanks!

-Mat

sql

Monday, February 20, 2012

Is bug 351711 fixed in MSDE 2000 SP1 or later?

I'm reading this article http://support.microsoft.com/?id=285100. I wonder
whether it is fixed or not in MSDE 2000 installation. If yes, fixed in which
SP?
The hot fix is released JAN-22-2001 and the article is Last Review : October
7, 2005. The article does not mention anything about whether the hot fix is
included in SP and it does not mention which SP does this bug applies to. By
reading the article, I will assume this only applies to MSDE 2000 without SP
and fixed in SP1. But can I assume that?Just download the latest MSDE version (Microsoft SQL Server 2000 Service Pack
4
http://www.microsoft.com/downloads/details.aspx?familyid=8E2DFC8D-C20E-4446-99A9-B7F0213F8BC5&displaylang=en
or directly from
http://www.microsoft.com/downloads/info.aspx?na=46&p=6&SrcDisplayLang=en&SrcCategoryId=&SrcFamilyId=8E2DFC8D-C20E-4446-99A9-B7F0213F8BC5&u=http%3a%2f%2fdownload.microsoft.com%2fdownload%2f1%2fb%2fd%2f1bdf5b78-584e-4de0-b36f-c44e06b0d2a3%2fSQL2000.MSDE-KB884525-SP4-x86-ENU.EXE&oRef=http%3a%2f%2fwww.microsoft.com%2fdownloads%2fdetails.aspx%3fFamilyId%3d413744D1-A0BC-479F-BAFA-E4B278EB9147%26displaylang%3den
"Peter" wrote:
> I'm reading this article http://support.microsoft.com/?id=285100. I wonder
> whether it is fixed or not in MSDE 2000 installation. If yes, fixed in which
> SP?
> The hot fix is released JAN-22-2001 and the article is Last Review : October
> 7, 2005. The article does not mention anything about whether the hot fix is
> included in SP and it does not mention which SP does this bug applies to. By
> reading the article, I will assume this only applies to MSDE 2000 without SP
> and fixed in SP1. But can I assume that?

Is bug 351711 fixed in MSDE 2000 SP1 or later?

I'm reading this article http://support.microsoft.com/?id=285100. I wonder
whether it is fixed or not in MSDE 2000 installation. If yes, fixed in whic
h
SP?
The hot fix is released JAN-22-2001 and the article is Last Review : October
7, 2005. The article does not mention anything about whether the hot fix i
s
included in SP and it does not mention which SP does this bug applies to. By
reading the article, I will assume this only applies to MSDE 2000 without SP
and fixed in SP1. But can I assume that?Just download the latest MSDE version (Microsoft SQL Server 2000 Service Pac
k
4)
http://www.microsoft.com/downloads/...&displaylang=en
or directly from:
http://www.microsoft.com/downloads/...r />
.MSDE-KB8
84525-SP4-x86-ENU.EXE&oRef=http%3a%2f%2fwww.microsoft.com%2fdownloads%2fdeta
ils.aspx%3fFamilyId%3d413744D1-A0BC-479F-BAFA-E4B278EB9147%26displaylang%3de
n
"Peter" wrote:

> I'm reading this article http://support.microsoft.com/?id=285100. I wonde
r
> whether it is fixed or not in MSDE 2000 installation. If yes, fixed in wh
ich
> SP?
> The hot fix is released JAN-22-2001 and the article is Last Review : Octob
er
> 7, 2005. The article does not mention anything about whether the hot fix
is
> included in SP and it does not mention which SP does this bug applies to.
By
> reading the article, I will assume this only applies to MSDE 2000 without
SP
> and fixed in SP1. But can I assume that?

Is BOL incomplete or incorrect? YOU can make it better!

If you think that the BOL page you're reading has incorrect or incomplete information, you can make it better by using the Send Feedback link that's available on every page.

It's easy for the SQL Server documentation team to miss documentation issues buried in newsgroup and forum postings. But when you use the Send Feedback link, an automated process creates a bug in our database and assigns it directly to the owner of the individual topic on which you've commented. Now there's no way I can miss it. And my boss sees it too.

Please help us to make SQL Server Books Online better by using the Send Feedback link whenever appropriate!

Thanks,

-Doug

SQL Server Integration Services documentation team


P.S. Don't use the BOL feedback mechanism to send product feature requests, product gripes, or product bug reports...they won't reach their destination. It's intended exclusively for issues with BOL content.

I think it's already pretty good for a beta, but I will remember your suggestion.

Keep up the good work!