RE: Resultat in eine Textdatei speichern

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



Hallo Saladin,

was bekommst du denn für Fehlermeldungen?
Ich würde mal anders vorgehen:

Datenbank auswählen -> rechte Maustaste -> All Tasks -> Export Data

Datasource wählen (deine DB)
Destination wählen (Textdatei)
Use a query to specify the data to transfer
Hier kannst du nun deine SP einsetzen (oder zum Test ein einfaches Statement
einsetzen)
Destination File Format wählen
Jetzt das ganze als DTS Package anlegen
Name, Description vergeben etc.

Nun hast du ein DTS Package, welches du schedulen kannst.
Und natürlich auch im Designer betrachten kannst.

Das Problem: Es wird immer in die gleiche Textdatei geschrieben.
Empfinde ich nicht als sinnvolle. Ich habe ein DTS Package mit einem VB
Script versehen, wo das Textfile immer einen eindeutigen Namen mit
Zeitstempel hat. Wenn du dieses haben möchtest, kann ich dir das sicher
irgendwie zukommen lassen.

Gruß,
Andreas



"Saladin" wrote:

Guten Tag,

ich habe eine Prozedur in der ein Select ausgeführt wird. Wenn ich
diese im Query Analyser ausführe erscheint unten das Resultat. Ich
möchte dass diese Prozedur regelmäßig ausgeführt wird und das Resultat
in einer Datei gespeichert wird. Ich habe es im DTS schon versucht
aber irgendwie nicht hinbekommen. Ich habe einen SQL Serer ausgewählt,
dann Textfile destination. Hierfür Task 'Daten Transformieren' und
hier hinein das gleiche SQL von der Prozedur genommen. Es kommen aber
Fehlermeldungen.

Wie kann ich am besten vorgehen. Gibt es vielleicht eine Beispiel.
Was muss ich denn in der Prozedur eintragen damit automatisch bei
Aufruf das Ergebnis gespeichert wird.

Vielen Dank für eure Hilfen
Saladin Hakverdi


Gespeicherte Prozedur:
CREATE Procedure product
AS
...
GO

.



Relevant Pages

  • Re: do I need Indexed Views for Replication
    ... is it possible to convert the DTS package to a publication and replicate ... from the DTS source server to what is currenly your publisher and also to ... replication of transactions or deltas. ... > Destination table: ...
    (microsoft.public.sqlserver.replication)
  • Re: DTS rollback ?
    ... then look in the tree to the left you will find all you need to know ... www.SQLDTS.com - The site for all your DTS needs. ... > I have a DTS package to replicate data from one site to another. ... > source data into the destination. ...
    (microsoft.public.sqlserver.dts)
  • Re: Variable text file destination name
    ... Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP) ... www.SQLDTS.com - The site for all your DTS needs. ... >>Allan Mitchell MCSE,MCDBA, ... >>> destination dynamically to Access or SQL databases I ...
    (microsoft.public.sqlserver.dts)
  • RE: DTS import failed on SETUSER command
    ... You should be table to xfer the Tables (owner xyz) from Source db ... to Destination db in the DTS Wizard by ... problem here using Diff users on Source/Destination but DTS was ... What if I have a user named 'abc' on destination and a user named ...
    (microsoft.public.sqlserver.dts)
  • Re: Transformation Data Task
    ... Make sure that DTS is Running in Transaction mode. ... make sure Commit on Successful package completion is True. ... > I'm using Transformation Data Task to copy data from one server to another ... I need source and destination connection parameter to set ...
    (microsoft.public.sqlserver.dts)