UFN_EDUCATIONALINSTITUTION_GETCITYFROMCONSTITUENT
Gets the CITY of the educational institution from the associated organization.
Return
Return Type |
---|
nvarchar(150) |
Parameters
Parameter | Parameter Type | Mode | Description |
---|---|---|---|
@EDUCATIONALINSTITUTIONID | uniqueidentifier | IN |
Definition
Copy
create function dbo.UFN_EDUCATIONALINSTITUTION_GETCITYFROMCONSTITUENT
(
@EDUCATIONALINSTITUTIONID uniqueidentifier
)
returns nvarchar(150)
with execute as caller
as begin
declare @RETVAL nvarchar(150);
select @RETVAL = ADDRESS.CITY
from dbo.CONSTITUENT
inner join dbo.ADDRESS
on ADDRESS.CONSTITUENTID = CONSTITUENT.ID
where (ADDRESS.ISPRIMARY = 1) and
(CONSTITUENT.ID = @EDUCATIONALINSTITUTIONID);
return @RETVAL;
end