I'd suggest using the mssql_XXXX functions, but in either case...
if you have a stored proc or view in your MS SQL Database, you call it simply by executing it as a query like so:
select * from table <-- query
exec sp_ProcName var1, var2 <-- stored proc
exec vw_ViewName <-- view
Enter them into the odbc_query() function ...