Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 need help to use cursors

Author  Topic 

Radhiga
Starting Member

35 Posts

Posted - 2006-04-17 : 04:16:50
Hai can anyone suggest me some website to learn and use cursors..im very new to this concept..
Thanks

khtan
In (Som, Ni, Yak)

17689 Posts

Posted - 2006-04-17 : 04:18:46
Just google for it.
http://www.databasejournal.com/features/mssql/article.php/1439731

Are you sure you are heading the right direction ? Cursor is not efficient and most of the time you can perform same things using set base operation and it is faster this way.



KH


Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2006-04-17 : 04:19:39
You can make use of sql server help file. Usually there may be better method than using Cursors.
What are you trying to do with Cursors?

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page

Radhiga
Starting Member

35 Posts

Posted - 2006-04-17 : 04:46:42
Ok,Thanks for the reply...
Actully my requirment is something similar to the below..
Tbl_MyCable_service
sid Serviceno servicename
1 CableTV 111111
2 LandLine 222222
3 Mobile 333333
4 Games 444444

TblCustomers

cid cname Services
1 John Games
2 John CableTV
3 John Landline

Now i want to genereate the report like the below

SNo cname services
1 John 444444,111111,222222
to perform this im planning to use cursors...B'coz both the tables doesnt have any unique key..Based on the Services the customer has taken i need to generate the report.
if u have any suggestion guide me pls
thanks
Go to Top of Page

khtan
In (Som, Ni, Yak)

17689 Posts

Posted - 2006-04-17 : 04:50:46
refer to this http://sqljunkies.com/WebLog/amachanic/archive/2004/11/10/5065.aspx



KH


Go to Top of Page
   

- Advertisement -