forums.silverfrost.com Forum Index forums.silverfrost.com
Welcome to the Silverfrost forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

FTN95 and SQLCLR

 
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> General
View previous topic :: View next topic  
Author Message
DrTip



Joined: 01 Aug 2006
Posts: 74
Location: Manchester

PostPosted: Wed Mar 14, 2007 10:47 am    Post subject: FTN95 and SQLCLR Reply with quote

Hi Paul

THis is a suggestion for future development

in the lastest version of SQL Server 2005. With some effort the ability to embed C# and VB.net functions has been added. THe main use of this functionality is to have the ability to do complex mathematics on databse columns.

THis is proving to be very useful to our company at the moment. We can have C# dlls embedded on the database to do numerical modelling without having to pull data out of the server.

In principle any .net language can be used though only c# and vb are supported (by microsoft) at the moment.
ftn95.net doesn't work because ftn95.net dlls access inappropriate system dlls (like windows forms etc)

Since the main use of FTN95 is for numerics and the main use of this new functionality is numerics this seems like perfect fit to me.


I know this is probably a specialised request but I can see you could steal an important march by getting this functionality up an running

Carl
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7916
Location: Salford, UK

PostPosted: Wed Mar 14, 2007 1:29 pm    Post subject: Reply with quote

Carl

Thanks for the suggestion. I would need further details before I understood exactly what you are looking for; maybe even a sample using the existing FTN95 so that we can find out why it fails in the given environment.
Back to top
View user's profile Send private message AIM Address
DrTip



Joined: 01 Aug 2006
Posts: 74
Location: Manchester

PostPosted: Thu Mar 15, 2007 11:01 am    Post subject: Reply with quote

Hil Paul

thanks for the reply

A simple example would be

--------------------------------------
integer function add (first, second)

integer first,second

add = first+second

end function
-----------------------------------

my steps were compile above function using clr version 2 to a dll

the step that failed was then in the sql server 2005 database

--
create assembly tesftn95 from 'c:\testftn95.dll'

this returns an error from the database saying the dll refers to ftn95lib.dll

I then attempted to load that dll on to the database but a similar message said the ftn95lib.dll refered to another dll like system.windows.forms I then gave up because I know forms are not allowed on the server.

this is a link to an example of how this stuff works using C#
http://msdn2.microsoft.com/ru-ru/library/ms131043.aspx

ultimately the aim is to have a function that can be used to add columns together or what ever using the the new function. obviously adding two columns is pretty piointless but running newton raphson iterations given a set of parameters might not be!


Carl
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> General All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group