Showing posts with label renaming. Show all posts
Showing posts with label renaming. Show all posts

Friday, March 30, 2012

Moving and renaming SSIS Projects

Say I created a new ssis Project and allowed the project to created a subfolder .. say both the project and subfolder are called x123.

I now want to rename the project to "Mycompany.MyProject" and want to remove the subfolder.

Possible?

Trying to avoid this, I made a copy of the parent folder, and manually tried to copy and paste all objects .. but am getting errors with connection manager entries.

Thanks for any help or information!

I think you need to edit the .sln and .dtproj files to reflect the new folder structure and names.

May be it is easier if you create a new project, and the use add existing package/item option to add the packages and other objects you want to preserve.

|||

Thanks. Copy and pasting finally worked. One quirk, if you paste in connections from another project it don't like that , but if you paste and then copy from new project and paste again and rename and then reset all all objects using the connections that seemed to work.

I'll try changing content of those files, but do suspect it will not be clean. It would be great if there were a utility or something.

sql

moving and renaming a file

I have a DTS package that I currently execute manually. This DTS package
reads a text file and imports it into a table.
I would like to have it run automaticly.
For that to work correctly, it would need to check to see if the txt file is
there (the name is always teh same), if it is not there, then to quit. If
it is there, to read and import it as normal, then once completed, for it to
rename teh file and move it to another location on teh computer.
How do I do that?I'd use ActiveXScipt and the FileSystemObject. Here is some sample code:
Function Main()
dim fso, source, dest, oldFile
set fso = CreateObject("Scripting.FileSystemObject")
source = "\\myBox\FAAIVR\BENEFIT_GROUP_INFO.txt"
oldFile = replace(source, ".txt", "_" & replace(date - 7, "/","_") & ".txt")
if (fso.FileExists(source)) then
dest = replace(source, ".txt", "_" & replace(date, "/","_") & ".txt")
fso.MoveFile source, dest
end if
if (fso.FileExists(oldFile)) then
fso.DeleteFile (oldFile)
"Johnfli" wrote:
> I have a DTS package that I currently execute manually. This DTS package
> reads a text file and imports it into a table.
> I would like to have it run automaticly.
> For that to work correctly, it would need to check to see if the txt file is
> there (the name is always teh same), if it is not there, then to quit. If
> it is there, to read and import it as normal, then once completed, for it to
> rename teh file and move it to another location on teh computer.
> How do I do that?
>
>