Hello Group, I am still fairly green in SQL, and I have a question.
I am creating a lookup using reporting services that finds an account based on lat/long. My question is how can I get results from a stored procedure to initialize variables in the following sp?
Example: --This sp will go out and get the minlat, maxlat, minlong, maxlong based on the zip code. EXEC SERVER.DATABASE.dbo.GetLatLongApprox @Zip
--Then I am declaring variables which I will use in the reporting services DECLARE @MaxLat AS float DECLARE @MinLat AS float DECLARE @MaxLong AS float DECLARE @MinLong AS float
--Now I want to dynamicaly set the values base on the results of the first stored procedure. SET @MaxLat = ? SET @MinLat = ? SET @MaxLong = ? SET @MinLong = ?
This will all reside in one stored procedure that I will use in reporting services. Hopefully this makes sense. Again, I am green and don't quite have the sql speak down yet.
Any help is greatly appreciated.