DocBook|Search
Class Reference
%Identity.Link1ResultSet
   
Server:basexml
Instance:SOAXML
User:UnknownUser
 
-
  [BASEXML] >  [%Identity] >  [Link1ResultSet]
Private  Storage  

class %Identity.Link1ResultSet extends %ResultSet.Custom

The Link1ResultSet class provides a %Library.IResultSet interface to the Link1^%Identity.match extrinsic function. A class wrapper for the Link1 method is documented in the class documentation of the %Identity.Data.Linkage class.

Example 1: Calling from Caché ObjectScript:

	  set searchFor = ##class(yourPackage.yourEntityClass).%New()
	  set searchFor.GivenName = givenName
	  set searchFor.Surname = surname
	  set searchFor.DateOfBirth = dateOfBirth
	  set rs = ##class(%ResultSet.Custom).%Prepare("%Identity.Link1ResultSet",.error,"",searchFor,linkageID,"",1,1)
	  while (rs.%Next(.sc))
	  {   w !,"[",rs.EntityID,",",rs.RowID,",",rs.Linkweight,",",rs.AgreePat,"]" 
	  }
	  do rs.%CloseCursor()
	  QUIT
Example 2: Calling from Java
  searchFor = yourPackage.yourEntityClass.%New();
  searchFor.GivenName = givenName;
  searchFor.Surname = surname;
  searchFor.DateOfBirth = dateOfBirth;
  rs = %ResultSet.Custom.%Prepare("%Identity.Link1ResultSet",error,"",searchFor,linkageID,"",1,1));
  while (rs.next()) 
  {    System.out.println( "[" + rs.EntityID + "," + rs.RowID + "," + rs.Linkweight + "," + rs.AgreePat + "]" );
  }
  rs.%CloseCursor()
Example 3: Calling from Perl
  $url = "localhost[1972]:Samples"
  $conn = Intersys::PERLBIND::Connection->new($url,"_SYSTEM","SYS",0);
  $database = Intersys::PERLBIND::Database->new($conn);
  $searchFor = $database->run_class_method("yourPackage.yourEntityClass","%New")
  $searchFor->set("GivenName","Joan");
  $searchFor->set("Surname","Doe");
  $searchFor->set("dateOfBirth",61153);
  rs = 
  while (@cols = $rs->fetch($sqlcode)) {
  {    $line = "[".cols[1].",".cols[2].",".cols[3].",".cols[4]."]"
       print "$line\n";
  }

Inventory

Parameters Properties Methods Queries Indices ForeignKeys Triggers
1 6 3


Summary

Properties
%Message %Metadata %PrivateTables %ROWCOUNT
%ROWID %ResultColumnCount %SQLCODE AgreePat
EntityID Linkweight RowID

Methods
%%OIDGet %AddToSaveSet %ClassIsLatestVersion %ClassName
%CloseCursor %ConstructClone %CreateSnapshot %DispatchClassMethod
%DispatchGetModified %DispatchGetProperty %DispatchMethod %DispatchSetModified
%DispatchSetMultidimProperty %Display %DisplayFormatted %ExecuteParametersGet
%Extends %Get %GetData %GetMetadata
%GetParameter %GetSerializedMetaData %IsA %IsModified
%MetadataGet %New %Next %NormalizeObject
%ObjectModified %OnNew %OriginalNamespace %PackageName
%Prepare %PrepareMetaData %Print %RemoveFromSaveSet
%ResultColumnCountGet %SendDelimitedRows %SendODBC %SerializeObject
%SetModified %ValidateObject


Parameters

• parameter ORDERBYENTITYID = 0;
Set the ORDERBYENTITYID to 1 to return results in EntityID order. By default the output is returned in descending order of Linkweight.

Properties

• property AgreePat as %String;
• property EntityID as %String;
• property Linkweight as %Numeric;
• property RowID as %String;

Methods

• method %CloseCursor() as %Status
Clean up on destruct
• method %Next(ByRef sc As %Library.Status) as %Library.Integer
Advance the result set cursor to the next row. Returns 0 if the cursor is at the end of the result set.