Hi Ewan,

Yes, it's possible to call a SP from an sql server, we use it a lot and it works fine.
Yes, it returns an Integer but usually that's not the result returned by the SP

the result is in %sqlcontext, I use it like this :

ClassMethod GetApptsSP(URNO As %String = "3123456") As %Status
{

  // calling the SP 
    set status = ##class(Hospital.SP.tpGetAppts).tpGetAppts(URNO)
 

   s rs=%sqlcontext.NextResult() // getting the result
    While rs.%Next() {

        s dateTime = rs.%Get("DueTimestamp")
        s ApptDate = $P(rs.%Get("DueTimestamp")," ",1)
     ....

}

 q $$$OK

}

hope this help