Hi,
i have simple requirement...but dont know how to proceed. I need to move the first record from a flat file (file1) to another flat file(file2) using SSIS, file1 will have many records but i just need the first one alone to be moved. Any pointers on this would be of much help.
Thanks,
raj
A batch file might be a better fit for this easy task:
Syntax:
getFirstLine.bat sourcefile > destinationfile
getFirstLine.bat
@.echo off
if %1'==' echo which file? && goto :eof
:main
set First=Y
for /f "tokens=*" %%L in (%1) do call :Getfirst %%L
goto :eof
:Getfirst
if %First%'==Y' echo %*
set First=N
goto :eof
:eof
|||Thanks Phil for your prompt reply, I managed to do the same using script component.
Thanks again
Raj
No comments:
Post a Comment