I have a query say “select name from books_det” ,and this query returns say 10 rows(name) , now i want to access the value of each and every row(i.e name) . How will i accomplish this in sybase?
I have tried
declare @var varchar
select @var=name from books_det //but this returns 10 rows i.e 10 name
print @var
go
This query doesn’t seems to give any result. Can anyone please help ?
It seems that you need a cursor.
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.help.ase_15.0.sqlug/html/sqlug/sqlug768.htm