[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

SQL Server Enterprise Manager --> Job Scheduling --> Export Output SQL-Query to File

Posted on 2008-11-11
8
Medium Priority
?
1,496 Views
Last Modified: 2012-06-27
how can i do this .. i know there is job scheduling .. but that option doenst give the possibily to choose between export formats .. i need lets say an export of a certain table (query) every day in a excel file or csv file..

right-click gives me the option to export the complete table .. but not schedules and not a certain query ..

Also in SQL Server Agent/Jobs/Add Job .. i dont know where to select an output file..

thanks in advanced



0
Comment
Question by:Amien90
  • 3
  • 3
  • 2
8 Comments
 
LVL 31

Expert Comment

by:James Murrell
ID: 22931855
in EM you can right click on the table you want to export, All tasks > Export Data - and the DTS Manager pops up and allows you to export in many formats, it will guide you through what to export, and when
0
 
LVL 9

Expert Comment

by:Ernariash
ID: 22931944

What is the version of MS SQL Server are you using? It seems you need DTS or SSIS.
Right-click gives you the option to export the complete table/view or Use Query, at the end of the wizard you have the option to save the DTS or the SSIS then you right click on the DTS or SSIS and  .. but not schedules and not a certain query to do an Schedule Package in 2000 or in 2005/2008 in agent wizard will allow you to select the SQL server Integration Service Package.
If you are using Reporting Services it could be a nice solution using subscriptions.
0
 
LVL 9

Expert Comment

by:Ernariash
ID: 22931977

Correction:
What is the version of MS SQL Server are you using? It seems you need DTS or SSIS.
Right-click gives you the option to export the complete table/view or Use Query, at the end of the wizard you have the option to save the DTS or the SSIS

In 2000: Then you right click on the DTS Schedule Package 
In 2005/2008: create a job wizard will allow you to select the SQL server Integration Service Package.
If you are using Reporting Services it could be a nice solution using subscriptions.
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:Amien90
ID: 22932095
Thanks..

when i add a job .. and then delete it in SQL Server agent .. and then add a job again.. i get this error when adding a new job:

Error Source: Microsoft OLE DB Provider for SQL Server

Error Description: DTS Package 'New Package' already exist with a different ID in this category .. do i need to delete something else?
0
 

Author Comment

by:Amien90
ID: 22932197
when exporting i get the following error:

Executed as user: test. DTSRun:  Loading...   DTSRun:  Executing...   DTSRun OnStart:  Copy Data from Results to C:\Documents and Settings\test Step   DTSRun OnError:  Copy Data from Results to C:\Documents and Settings\test Step, Error = -2147467259 (80004005)      Error string:  Error opening datafile: Access is denied.         Error source:  Microsoft Data Transformation Services Flat File Rowset Provider      Help file:  DTSFFile.hlp      Help context:  0      Error Detail Records:      Error:  5 (5); Provider Error:  5 (5)      Error string:  Error opening datafile: Access is denied.         Error source:  Microsoft Data Transformation Services Flat File Rowset Provider      Help file:  DTSFFile.hlp      Help context:  0      DTSRun OnFinish:  Copy Data from Results to C:\Documents and Settings\test Step   DTSRun:  Package execution complete.  Process Exit Code 1.  The step failed.

seems like i dont have access to the datafile .. this while SQL Server Enterprise manager should have access cause i'm running queries from the database.
0
 
LVL 31

Expert Comment

by:James Murrell
ID: 22932233
has any one changed the local admin password
0
 

Author Comment

by:Amien90
ID: 22932322
local admin password was not changed
i'm using MS SQL Enterprise Manager V8

so .. a job was added .. i had the possibily to make a query and select output  file .. but now i have two issues:

1. error when job is executed
2. DTS Package 'New Package' already exist with a different ID in this category .. issue
0
 
LVL 9

Accepted Solution

by:
Ernariash earned 1500 total points
ID: 22932687
Please try 'New Package'  "save as" using "Use Windows Authentication" and change the name. Please  check that the owner have admin privileges on the sql server. you could  try changing the location to "Structured storage file".
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

What if you have to shut down the entire Citrix infrastructure for hardware maintenance, software upgrades or "the unknown"? I developed this plan for "the unknown" and hope that it helps you as well. This article explains how to properly shut down …
Windocks is an independent port of Docker's open source to Windows.   This article introduces the use of SQL Server in containers, with integrated support of SQL Server database cloning.
This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function
Viewers will learn how to use the UPDATE and DELETE statements to change or remove existing data from their tables. Make a table: Update a specific column given a specific row using the UPDATE statement: Remove a set of values using the DELETE s…
Suggested Courses

834 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question