Showing posts with label wan. Show all posts
Showing posts with label wan. Show all posts

Thursday, March 29, 2012

FTP task - StopOnFailure not working as I expect?

Hi

I'm using an FTP task in a loop to download files from a WAN based FTP server. I've got a script to generate the name of the file I require and place into a variable. Problem is sometimes some of the remote files haven't been published so the FTP component errors and the package fails.

I tried setting StopOnFailure to False - all I get is the following errors

[FTP Task] Error: File represented by "User::RemotePath" does not exist.
[FTP Task] Error: Attempt to read message string for 0x80020918 failed with error 0xc02090f3. Make sure all message related files are registered.

What I want to do is ignore the error and perform the next loop iteration

Is this a bug, or am I missing something

Dave

To ignore the ftp task error within a loop, put an OnError event handler on the FTP task. In the handler, set the System::Propagate variable to false. This setting will keep the error(s) in the ftp task from bubbling up the container hierarchy, and thus keep the loop from failing on a missing file.

For example:

Imports Microsoft.SqlServer.Dts.Runtime

Public Class ScriptMain
Private vars As Variables
Public Sub Main()
Dts.TaskResult = Dts.Results.Success
Dts.VariableDispenser.LockForWrite("System::Propagate")
Dts.VariableDispenser.GetVariables(vars)
vars("System::Propagate").Value = False
vars.Unlock()
End Sub
End Class

P.S. Another way to ignore the ftp error is by configuring the MaximumErrorCount property on the loop executable to some relatively high number.
|||Excellent thanks, I initially set the MaximumErrorCount as a quick hack but thanks for the first suggestion - I've been meaning to figure out how OnError works.

|||

This sounds like the perfect solution for what I'm trying to do... but one question:

How do you "put an OnEvent handler on the ftp task"?

Not sure what this means.

Thanks much!!

|||

Ok, I figured out the event handler tab functionality.

So, for my FTP task, I created an OnError event handler. I put a script task in the event handler.

Imports Microsoft.SqlServer.Dts.Runtime

Public Class ScriptMain
Private vars As Variables
Public Sub Main()
Dts.TaskResult = Dts.Results.Success
Dts.VariableDispenser.LockForWrite("System:Stick out tongueropagate")
Dts.VariableDispenser.GetVariables(vars)
vars("System:Stick out tongueropagate").Value = False
vars.Unlock()
End Sub
End Class

However, the FTP task is still failing as before, and failing the ForLoop container with it.

What am I doing wrong?

Thanks

|||

Hello,

I am still trying to figure out why FTP the error is still "bubbling up" to the ForLoop container?

This is what I have:

ForLoop [ FTP task --> script task ]

In the FTP task Event Handler tab, I created an "On Error" event handler. It is a script task with the above poster's code that is supposed to turn off the System propogate variable. However, it isn't working. What am I doing wrong?

I need to turn off error handers in the FTP task, so that when I get a file not found error, it doesn't cause the ForLoop container to fail also. It needs to keep looping, even if the file isn't there yet.

Thanks much!

|||

The system variable System:Stick out tongueropagate effects propagation of execution errors. Validation errors will always propagate at least one level up the container hierarchy, probably because the validation error of a task becomes an execution error of the for loop container.

So if an error occurs in the validation phase of the ftp task, the first time a System:Stick out tongueropagate=false error handler could catch it would be in the for each loop. Execution errors, on the other hand, can be caught be an error handler on the ftp task itself.

The two properties which also account for validation errors (which always bubble up at least one level) are ForceExecutionResult and MaximumErrorCount. By setting ForceExecutionResult=Sucess on the for each loop container or by setting MaximumErrorCount on the for each loop container to a large number, the loop will continue.

You can determine in which phase the the error(s) occur by observing if the error events fall exclusively between the OnPrevalidate / OnPostValidate events of the ftp task.

FTP task - StopOnFailure not working as I expect?

Hi

I'm using an FTP task in a loop to download files from a WAN based FTP server. I've got a script to generate the name of the file I require and place into a variable. Problem is sometimes some of the remote files haven't been published so the FTP component errors and the package fails.

I tried setting StopOnFailure to False - all I get is the following errors

[FTP Task] Error: File represented by "User::RemotePath" does not exist.
[FTP Task] Error: Attempt to read message string for 0x80020918 failed with error 0xc02090f3. Make sure all message related files are registered.

What I want to do is ignore the error and perform the next loop iteration

Is this a bug, or am I missing something

Dave

To ignore the ftp task error within a loop, put an OnError event handler on the FTP task. In the handler, set the System::Propagate variable to false. This setting will keep the error(s) in the ftp task from bubbling up the container hierarchy, and thus keep the loop from failing on a missing file.

For example:

Imports Microsoft.SqlServer.Dts.Runtime

Public Class ScriptMain
Private vars As Variables
Public Sub Main()
Dts.TaskResult = Dts.Results.Success
Dts.VariableDispenser.LockForWrite("System::Propagate")
Dts.VariableDispenser.GetVariables(vars)
vars("System::Propagate").Value = False
vars.Unlock()
End Sub
End Class

P.S. Another way to ignore the ftp error is by configuring the MaximumErrorCount property on the loop executable to some relatively high number.
|||Excellent thanks, I initially set the MaximumErrorCount as a quick hack but thanks for the first suggestion - I've been meaning to figure out how OnError works.|||

This sounds like the perfect solution for what I'm trying to do... but one question:

How do you "put an OnEvent handler on the ftp task"?

Not sure what this means.

Thanks much!!

|||

Ok, I figured out the event handler tab functionality.

So, for my FTP task, I created an OnError event handler. I put a script task in the event handler.

Imports Microsoft.SqlServer.Dts.Runtime

Public Class ScriptMain
Private vars As Variables
Public Sub Main()
Dts.TaskResult = Dts.Results.Success
Dts.VariableDispenser.LockForWrite("System:Stick out tongueropagate")
Dts.VariableDispenser.GetVariables(vars)
vars("System:Stick out tongueropagate").Value = False
vars.Unlock()
End Sub
End Class

However, the FTP task is still failing as before, and failing the ForLoop container with it.

What am I doing wrong?

Thanks

|||

Hello,

I am still trying to figure out why FTP the error is still "bubbling up" to the ForLoop container?

This is what I have:

ForLoop [ FTP task --> script task ]

In the FTP task Event Handler tab, I created an "On Error" event handler. It is a script task with the above poster's code that is supposed to turn off the System propogate variable. However, it isn't working. What am I doing wrong?

I need to turn off error handers in the FTP task, so that when I get a file not found error, it doesn't cause the ForLoop container to fail also. It needs to keep looping, even if the file isn't there yet.

Thanks much!

|||

The system variable System:Stick out tongueropagate effects propagation of execution errors. Validation errors will always propagate at least one level up the container hierarchy, probably because the validation error of a task becomes an execution error of the for loop container.

So if an error occurs in the validation phase of the ftp task, the first time a System:Stick out tongueropagate=false error handler could catch it would be in the for each loop. Execution errors, on the other hand, can be caught be an error handler on the ftp task itself.

The two properties which also account for validation errors (which always bubble up at least one level) are ForceExecutionResult and MaximumErrorCount. By setting ForceExecutionResult=Sucess on the for each loop container or by setting MaximumErrorCount on the for each loop container to a large number, the loop will continue.

You can determine in which phase the the error(s) occur by observing if the error events fall exclusively between the OnPrevalidate / OnPostValidate events of the ftp task.

FTP task - StopOnFailure not working as I expect?

Hi

I'm using an FTP task in a loop to download files from a WAN based FTP server. I've got a script to generate the name of the file I require and place into a variable. Problem is sometimes some of the remote files haven't been published so the FTP component errors and the package fails.

I tried setting StopOnFailure to False - all I get is the following errors

[FTP Task] Error: File represented by "User::RemotePath" does not exist.
[FTP Task] Error: Attempt to read message string for 0x80020918 failed with error 0xc02090f3. Make sure all message related files are registered.

What I want to do is ignore the error and perform the next loop iteration

Is this a bug, or am I missing something

Dave

To ignore the ftp task error within a loop, put an OnError event handler on the FTP task. In the handler, set the System::Propagate variable to false. This setting will keep the error(s) in the ftp task from bubbling up the container hierarchy, and thus keep the loop from failing on a missing file.

For example:

Imports Microsoft.SqlServer.Dts.Runtime

Public Class ScriptMain
Private vars As Variables
Public Sub Main()
Dts.TaskResult = Dts.Results.Success
Dts.VariableDispenser.LockForWrite("System::Propagate")
Dts.VariableDispenser.GetVariables(vars)
vars("System::Propagate").Value = False
vars.Unlock()
End Sub
End Class

P.S. Another way to ignore the ftp error is by configuring the MaximumErrorCount property on the loop executable to some relatively high number.
|||Excellent thanks, I initially set the MaximumErrorCount as a quick hack but thanks for the first suggestion - I've been meaning to figure out how OnError works.

|||

This sounds like the perfect solution for what I'm trying to do... but one question:

How do you "put an OnEvent handler on the ftp task"?

Not sure what this means.

Thanks much!!

|||

Ok, I figured out the event handler tab functionality.

So, for my FTP task, I created an OnError event handler. I put a script task in the event handler.

Imports Microsoft.SqlServer.Dts.Runtime

Public Class ScriptMain
Private vars As Variables
Public Sub Main()
Dts.TaskResult = Dts.Results.Success
Dts.VariableDispenser.LockForWrite("System:Stick out tongueropagate")
Dts.VariableDispenser.GetVariables(vars)
vars("System:Stick out tongueropagate").Value = False
vars.Unlock()
End Sub
End Class

However, the FTP task is still failing as before, and failing the ForLoop container with it.

What am I doing wrong?

Thanks

|||

Hello,

I am still trying to figure out why FTP the error is still "bubbling up" to the ForLoop container?

This is what I have:

ForLoop [ FTP task --> script task ]

In the FTP task Event Handler tab, I created an "On Error" event handler. It is a script task with the above poster's code that is supposed to turn off the System propogate variable. However, it isn't working. What am I doing wrong?

I need to turn off error handers in the FTP task, so that when I get a file not found error, it doesn't cause the ForLoop container to fail also. It needs to keep looping, even if the file isn't there yet.

Thanks much!

|||

The system variable System:Stick out tongueropagate effects propagation of execution errors. Validation errors will always propagate at least one level up the container hierarchy, probably because the validation error of a task becomes an execution error of the for loop container.

So if an error occurs in the validation phase of the ftp task, the first time a System:Stick out tongueropagate=false error handler could catch it would be in the for each loop. Execution errors, on the other hand, can be caught be an error handler on the ftp task itself.

The two properties which also account for validation errors (which always bubble up at least one level) are ForceExecutionResult and MaximumErrorCount. By setting ForceExecutionResult=Sucess on the for each loop container or by setting MaximumErrorCount on the for each loop container to a large number, the loop will continue.

You can determine in which phase the the error(s) occur by observing if the error events fall exclusively between the OnPrevalidate / OnPostValidate events of the ftp task.

sql

Friday, March 23, 2012

Frustrated with two clients that can't connect...

I have a SQL server that I am trying to access from across a WAN. 1 machine
of the 3 machines will connect ok, the other 2 machine's will not. The SQL
server is using Named Pipes. On all 3 machines I can do a net view
\\servername and have it come back ok. I've tried both SQL auth and Windows
auth and both work on the machine that can connect and both fail on the
machine's that won't.
How do you troubleshoot a client that won't connect?
Is there a SQL client configuration utility? If so how do I run it /
install it?
My debugging application allows me to get to a "Data Link Properties" dialog
that allows me to try settings. Can you get to this dialog on any machine?
How can I invoke it? I remember something about creating an empty file with
a specific extension and going to its properties but I may be thinking of
ODBC.
Any ideas?
Thanks,
SA Dev
"SA Development" <nospam38925@.forme.com> wrote in message
news:3tCdnYtUxJwY793fRVn-1A@.valortelecom.com...
>I have a SQL server that I am trying to access from across a WAN. 1
>machine of the 3 machines will connect ok, the other 2 machine's will not.
>The SQL server is using Named Pipes. On all 3 machines I can do a net view
>\\servername and have it come back ok. I've tried both SQL auth and
>Windows auth and both work on the machine that can connect and both fail on
>the machine's that won't.
> How do you troubleshoot a client that won't connect?
> Is there a SQL client configuration utility? If so how do I run it /
> install it?
It's called "Client Network Utility". Install the SQL Tools from the SQL
Server CD, and make sure your client is using the same protocols, etc., as
the Server (use the Server Network Utility on the Server to determine this).
BTW, what version of SQL Server are you using? Are the 3 machines
configured similarly? Same Network protocols, same firewall settings (if
any), etc.?

> My debugging application allows me to get to a "Data Link Properties"
> dialog that allows me to try settings. Can you get to this dialog on any
> machine? How can I invoke it? I remember something about creating an
> empty file with a specific extension and going to its properties but I may
> be thinking of ODBC.
You can test your server connection from the ODBC Administrator by creating
an ODBC DSN in it and, when done, click on the Test button.
Is this an application you are developing or a pre-packaged app? If it's an
app you're developing, you might need to re-visit your connection string
settings. If it's a pre-packaged app, you will probably have to scan their
documentation for specific configuration info.

Frustrated with two clients that can't connect...

I have a SQL server that I am trying to access from across a WAN. 1 machine
of the 3 machines will connect ok, the other 2 machine's will not. The SQL
server is using Named Pipes. On all 3 machines I can do a net view
\\servername and have it come back ok. I've tried both SQL auth and Windows
auth and both work on the machine that can connect and both fail on the
machine's that won't.
How do you troubleshoot a client that won't connect?
Is there a SQL client configuration utility? If so how do I run it /
install it?
My debugging application allows me to get to a "Data Link Properties" dialog
that allows me to try settings. Can you get to this dialog on any machine?
How can I invoke it? I remember something about creating an empty file with
a specific extension and going to its properties but I may be thinking of
ODBC.
Any ideas?
Thanks,
SA Dev"SA Development" <nospam38925@.forme.com> wrote in message
news:3tCdnYtUxJwY793fRVn-1A@.valortelecom.com...
>I have a SQL server that I am trying to access from across a WAN. 1
>machine of the 3 machines will connect ok, the other 2 machine's will not.
>The SQL server is using Named Pipes. On all 3 machines I can do a net view
>\\servername and have it come back ok. I've tried both SQL auth and
>Windows auth and both work on the machine that can connect and both fail on
>the machine's that won't.
> How do you troubleshoot a client that won't connect?
> Is there a SQL client configuration utility? If so how do I run it /
> install it?
It's called "Client Network Utility". Install the SQL Tools from the SQL
Server CD, and make sure your client is using the same protocols, etc., as
the Server (use the Server Network Utility on the Server to determine this).
BTW, what version of SQL Server are you using? Are the 3 machines
configured similarly? Same Network protocols, same firewall settings (if
any), etc.?

> My debugging application allows me to get to a "Data Link Properties"
> dialog that allows me to try settings. Can you get to this dialog on any
> machine? How can I invoke it? I remember something about creating an
> empty file with a specific extension and going to its properties but I may
> be thinking of ODBC.
You can test your server connection from the ODBC Administrator by creating
an ODBC DSN in it and, when done, click on the Test button.
Is this an application you are developing or a pre-packaged app? If it's an
app you're developing, you might need to re-visit your connection string
settings. If it's a pre-packaged app, you will probably have to scan their
documentation for specific configuration info.

Frustrated with two clients that can't connect...

I have a SQL server that I am trying to access from across a WAN. 1 machine
of the 3 machines will connect ok, the other 2 machine's will not. The SQL
server is using Named Pipes. On all 3 machines I can do a net view
\\servername and have it come back ok. I've tried both SQL auth and Windows
auth and both work on the machine that can connect and both fail on the
machine's that won't.
How do you troubleshoot a client that won't connect?
Is there a SQL client configuration utility? If so how do I run it /
install it?
My debugging application allows me to get to a "Data Link Properties" dialog
that allows me to try settings. Can you get to this dialog on any machine?
How can I invoke it? I remember something about creating an empty file with
a specific extension and going to its properties but I may be thinking of
ODBC.
Any ideas?
Thanks,
SA Dev"SA Development" <nospam38925@.forme.com> wrote in message
news:3tCdnYtUxJwY793fRVn-1A@.valortelecom.com...
>I have a SQL server that I am trying to access from across a WAN. 1
>machine of the 3 machines will connect ok, the other 2 machine's will not.
>The SQL server is using Named Pipes. On all 3 machines I can do a net view
>\\servername and have it come back ok. I've tried both SQL auth and
>Windows auth and both work on the machine that can connect and both fail on
>the machine's that won't.
> How do you troubleshoot a client that won't connect?
> Is there a SQL client configuration utility? If so how do I run it /
> install it?
It's called "Client Network Utility". Install the SQL Tools from the SQL
Server CD, and make sure your client is using the same protocols, etc., as
the Server (use the Server Network Utility on the Server to determine this).
BTW, what version of SQL Server are you using? Are the 3 machines
configured similarly? Same Network protocols, same firewall settings (if
any), etc.?
> My debugging application allows me to get to a "Data Link Properties"
> dialog that allows me to try settings. Can you get to this dialog on any
> machine? How can I invoke it? I remember something about creating an
> empty file with a specific extension and going to its properties but I may
> be thinking of ODBC.
You can test your server connection from the ODBC Administrator by creating
an ODBC DSN in it and, when done, click on the Test button.
Is this an application you are developing or a pre-packaged app? If it's an
app you're developing, you might need to re-visit your connection string
settings. If it's a pre-packaged app, you will probably have to scan their
documentation for specific configuration info.

Friday, March 9, 2012

freeze columns (not headers

I have many columns out to the right. The name column is the first column in
the report. I wan to "freeze" the name column so that when you scroll to the
right in the report the name column is still visible.
From this forum i learn that freeze headers isn't available until RS 2005.
Is this the same case for Freeze columns?
Does anyone else try to do this?I'm not sure that Freeze Columns will even be available in the initial RS
2005 release. I haven't heard anything about it and it's a feature that I
would love to see.
Currently the only way to accomplish these things are to programmatically
pull reports from RS and save the resulting output file. Then your
application must open the Excel file and manipulate it directly. You'll need
to have a way for the application to know which columns/rows get frozen for
each report that you have.
It's doable, but you have to have a lot of custom code done and it does slow
down the delivery speed some.
"Phillip" wrote:
> I have many columns out to the right. The name column is the first column in
> the report. I wan to "freeze" the name column so that when you scroll to the
> right in the report the name column is still visible.
> From this forum i learn that freeze headers isn't available until RS 2005.
> Is this the same case for Freeze columns?
> Does anyone else try to do this?|||It will be available in RS 2005.
-- Robert
This posting is provided "AS IS" with no warranties, and confers no rights.
"Todd" <Todd@.discussions.microsoft.com> wrote in message
news:F6011202-F219-48FB-8674-EEA5E938FEA2@.microsoft.com...
> I'm not sure that Freeze Columns will even be available in the initial RS
> 2005 release. I haven't heard anything about it and it's a feature that I
> would love to see.
> Currently the only way to accomplish these things are to programmatically
> pull reports from RS and save the resulting output file. Then your
> application must open the Excel file and manipulate it directly. You'll
> need
> to have a way for the application to know which columns/rows get frozen
> for
> each report that you have.
> It's doable, but you have to have a lot of custom code done and it does
> slow
> down the delivery speed some.
> "Phillip" wrote:
>> I have many columns out to the right. The name column is the first column
>> in
>> the report. I wan to "freeze" the name column so that when you scroll to
>> the
>> right in the report the name column is still visible.
>> From this forum i learn that freeze headers isn't available until RS
>> 2005.
>> Is this the same case for Freeze columns?
>> Does anyone else try to do this?