create procedure Sql2Txt(@FilePath varchar(500))
as
begin
EXEC master..xp_cmdshell  'bcp  "stueval2..result" out @FilePath -c  -S (local)  -U sa -P'
end
exec 'c:\123.txt'