jafm Posted August 2, 2012 at 02:59 PM Report #471299 Posted August 2, 2012 at 02:59 PM Olá, A minha questão é, tenho informação de uma tabela no sql server, e gostaria de fazer uma mecanismo que me mandasse essa informaçao para um ficherio txt?
ricasss Posted August 3, 2012 at 04:53 PM Report #471406 Posted August 3, 2012 at 04:53 PM Que tipo de informação?
renafi Posted August 4, 2012 at 01:27 AM Report #471444 Posted August 4, 2012 at 01:27 AM Mas queres ter uma aplicação para fazer isso, ou basta uma rotina para o sql server fazer isso? se for a ultima opção, pesquisa por Integration Services. Mas para uma coisa tão simples, há na net scripts para o sql server exportar para txt.... Oracle Certified Professional - AdministraçãoOracle Certified Professional - Pl/sqlMCPD - Microsoft Certified Professional DeveloperMCTS - Microsoft Certified Technology Specialist
jafm Posted August 9, 2012 at 04:12 PM Author Report #471874 Posted August 9, 2012 at 04:12 PM Boas, Tentei usar este sript EXEC xp_cmdshell 'bcp "SELECT * FROM Paises" queryout "C:\teste.txt" -T -c -t,' Mas está a dar o seguinte erro: SQLState = 08001, NativeError = 2 Error = [Microsoft] Named Pipes Provider: Could not open a connection to SQL Server [2]. SQLState = 08001, NativeError = 2 Error = [Microsoft][sql Server Native Client 10.0]A network-related or instance-specific error has occurred while establishing a connection to SQL Server. Server is not found or not accessible. Check if instance name is correct and if SQL Server is config ured to allow remote connections. For more information see SQL Server Books Online. SQLState = S1T00, NativeError = 0 Error = [Microsoft][sql Server Native Client 10.0]Login timeout expired NULL Alguém ,e consegue ajudar?
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now