Showing posts with label txt. Show all posts
Showing posts with label txt. Show all posts

Tuesday, March 27, 2012

Copy Flat File between two server; Help me please.

Hello All,

I want to copy flat file(.txt) from server to another server.

server A(Source Folder) ====> server B(Achive Folder)

Can I do it?

Please, help me.

Thank you very much.

Chonnathan

Do you want to perform this copy once or on a regular schedule? There are probably better utilities out there to perform this server-to-server copy, other than SSIS regardless.|||

Hi again,

Now, I want to use SSIS to process data from text(banking transactions, credit card) in daily process.

but source file was in another server.

In this case how can i do to get source file to precess in ssis on other server.

thank you very much.

My english skill is not well, sorry.

|||You'll have to use FTP or some other means of getting that file off of the source server. There is an FTP task in the control flow of SSIS. Or, if you can map a network drive to the source server, you can simply use a flat file source connection in the data flow against that mapped drive/file.|||

Great job,

Thank you for your helpful,

Regards,

Chonnathan

|||

Chonnathan Parnprom wrote:

Great job,

Thank you for your helpful,

Regards,

Chonnathan

I've I've answered your question, please mark it as answered using the "Mark as Answer" button.

Thanks,

Phil

Wednesday, March 7, 2012

copy content of txt file

Hi Guys,

What approach should I use to copy content of a text file. Is BCP capable of doing this? How about SSIS?

Example of the text file's content:

Date, "20060101"
ST_Code, "101"
A_Code, P_Code, T_Code, amount, price
"0001", "1111", "0101", 550, 230
"0002", "1111", "0102", 345, 122
"2001", 0212", 0930", 410, 90

In the example above, I just want to copy the rows Date, "20060101" and ST_Code, "101" into a table.

Regards,

Lars

Hi,

You could use DTS for this. Define a new DTS package, with your database in source, and a text file for output.

You can use an SQL order to filter your Data (..Where Date = "20060101" AND ....).

The result will be formatted as a CVS file by default. If you need to personalize your output format, you can use ActiveX scripts in transformation tasks to do this

ex :

Function Main()
DTSDestination("Date") = "Date, " & DTSSource("Date")
Main = DTSTransformStat_OK
End Function

|||

hi,

if you know the location of the row you want to copy you can use

the -f anf -l switch of BCP which stands for

-f = the first row

-l = the lastrow

regards,

joey