User's Manual
Virtuoso 4.5 Application and Integration Reviewers Guide  
Copyright ©2006 OpenLink Software     
22 
member (method) to calculate the distance between points. Note that 
"Point" class is computing the distance between two arbitrary points and the 
arbitrary values 1 & 2 as input parameters for the Stored Procedure 
"distance" whose definition is show below in Figure 28 – Distance Stored 
Procedure. 
Figure 28 – Distance Stored Procedure 
CREATE procedure clr..distance (in x1 integer, in y1 integer, in x2 
integer, in y2 integer) 
returns float 
 { 
 return new DB.DBA.Point(x1, y1).distance (new DB.DBA.Point (x2, y2)); 
} 
Step 8.  Once the distance stored procedure has been created, we then publish the 
procedure as a web service using the method previously shown in the section 
Publishing SQL Stored Procedures as Web Services. 
Step 9.  Using the Virtuoso generated vsmx page, a SOAP Service can be invoked for 
the procedure for testing as seen Figure 29 – Testing CLR UDT and 
distance stored procedure and Figure 30 - Testing the SOAP 
Operation, Distance. 










