dbTalk Databases Forums  

DTS error - and global var -file name Q

microsoft.public.sqlserver.dts microsoft.public.sqlserver.dts


Discuss DTS error - and global var -file name Q in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Jeff User
 
Posts: n/a

Default DTS error - and global var -file name Q - 06-01-2006 , 11:45 AM






Hi all
I looked at Allens article
http://www.sqldts.com/default.aspx?246

and am trying to get this to work.

My problem and what I dont understand is this: The program uses a
global variable that is supposed to contain a file name:
gv_FileFullName. Well, the point of the program is to loop through
several/more than one files.
Q1) What am I supposed to put in the global variable? A wild card
value?

- My filenames are of the format "yyyymmddhhmmss.ent.f" .
- So I put this "C:\mydatafiels\*.ent.f" in for my global var
value.
- So far I only have one test file in the directory.
- The package runs and loads the data but
- then the loop around code (Step 6) throws an error stating that
"the file already exists" when it attempts to move the file to the
archive dir. I look in archive directory and it is still empty.
I double checked the path for gv_ArchiveLocation and it is set to
where I want to files to go.

After this runs and fails (with above stated error) , when I go back
and look at the global file name variable it now contains the entire
filename, rather than my wildcard entry.
Q2) Why does this change and/or Am I supposed to specify my filename
wild card (format) somewhere other than the global var??

Not sure if this is two seperate issues or not, but I seem to be stuck
in the area of the filename.

Thanks much
Jeff



Reply With Quote
  #2  
Old   
Jeff User
 
Posts: n/a

Default Re: DTS error - and global var -file name Q - 06-01-2006 , 03:02 PM







Hi all
Some progress. The file already exists error was caused because the
value for the global variable did not end with a slash "\". Therefore,
it was trying to copy the file to itself.

Now, the transformation itself, only runs once. After the file is
moved to the archive folder, the transformation is still looking for
the file with the same name as before. The transformation has to have
a filename as a source, but it will not accept wild card values. How
is the source file name, supposed to be supplied to the transformation
dynamically ? I don't see where this should happen and apparently it
is not.

Thanks again for advice
Jeff



On Thu, 01 Jun 2006 12:45:50 -0400, Jeff User <jeff31162 (AT) hotmail (DOT) com>
wrote:

Quote:
Hi all
I looked at Allens article
http://www.sqldts.com/default.aspx?246

and am trying to get this to work.

My problem and what I dont understand is this: The program uses a
global variable that is supposed to contain a file name:
gv_FileFullName. Well, the point of the program is to loop through
several/more than one files.
Q1) What am I supposed to put in the global variable? A wild card
value?

- My filenames are of the format "yyyymmddhhmmss.ent.f" .
- So I put this "C:\mydatafiels\*.ent.f" in for my global var
value.
- So far I only have one test file in the directory.
- The package runs and loads the data but
- then the loop around code (Step 6) throws an error stating that
"the file already exists" when it attempts to move the file to the
archive dir. I look in archive directory and it is still empty.
I double checked the path for gv_ArchiveLocation and it is set to
where I want to files to go.

After this runs and fails (with above stated error) , when I go back
and look at the global file name variable it now contains the entire
filename, rather than my wildcard entry.
Q2) Why does this change and/or Am I supposed to specify my filename
wild card (format) somewhere other than the global var??

Not sure if this is two seperate issues or not, but I seem to be stuck
in the area of the filename.

Thanks much
Jeff



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.