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)
 Cursor

Author  Topic 

avats
Starting Member

5 Posts

Posted - 2005-02-20 : 22:29:10
Hi
can anyone tell about
1. I am deleting some records while using cursor.How can I suppress the message (n records affected).
2. How can I save the records queried by cursor in a .txt file?
Thanx
avats

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2005-02-21 : 01:20:50
Hi,

(1) Set Nocount on
(2) exec xp_cmdshell 'bcp "select * from dbname..tablename" queryout "filename" -c'

Madhivanan
Go to Top of Page
   

- Advertisement -