December 6, 2006 at 9:43 am
yes its working if i omit the last line. is my query correct?
December 6, 2006 at 9:45 am
i see only that you must specify the attachment as a string so:
@attachments = 'C:\Documents and Settings\Desktop\test.xls'
that is different from
@attachments = C:\Documents and Settings\Desktop\test.xls'
sorry for my english...
December 6, 2006 at 9:47 am
a typo mistake
but why is it working if i omit the attachments. i am getting the email. does it effect anything if i use xp_stopmail
December 6, 2006 at 10:04 am
I just modified my DTSPackage and the activexscript worked perfect with out failing the package.
sorry its my fault; didnt make the connections properly.
Thats really good. Thanks a lot RLoski for the script.
But the xpsend_mail is not working properly. anyways i have one solution and i am good to go.
December 6, 2006 at 10:08 am
if anyone can give me a solution for xp_sendmail that would be great. I didnt use xp_sendmail till now and this is the first time i tested with it. Just curious to know as to how the attachments can be sent.
Thanks.
December 6, 2006 at 12:03 pm
Hi i am back again. The active x script works fine but a problem here.
Function Main()
if DTSGlobalVariables.Parent.Tasks("DTSTask_DTSDataPumpTask_2").CustomTask.RowsComplete < 0 then
' 0 or some other threshold
Main = DTSStepScriptResult_DontExecuteTask
else
Main = DTSStepScriptResult_ExecuteTask
end if
end function
what should be the threshold that i need to mention here. Here is my scenario
one of my table doesnt have errors so the excel part shouldnt run and the other table has got errors this time the excel part should run. so if i mention the threshold as <0 i see that the excel part is running for both the scenarios. I tried putting different values but no luck. Please help me out.
Thanks for your reply
December 6, 2006 at 4:16 pm
Under what conditions does the task run? You can set up a workflow from the datapump to this task. You can state that you want the routine to only when there is an error (or is no error).
Russ
Russel Loski, MCSE Business Intelligence, Data Platform
December 6, 2006 at 8:43 pm
The task should not run when the number of errored records is zero. if there are any errored records it should send to the excel and then send an email with the attachment of this excel. can u tell me as to how to set up the workflow from the datapump to this task.
Thanks for ur reply.
December 7, 2006 at 6:14 am
Try:
if DTSGlobalVariables.Parent.Tasks("DTSTask_DTSDataPumpTask_2").CustomTask.RowsComplete = 0 then
Russel Loski, MCSE Business Intelligence, Data Platform
January 2, 2007 at 10:31 am
Hi Russel,
I am back again. I was on vacation these days so couldnt check your message. I tried giving
if DTSGlobalVariables.Parent.Tasks("DTSTask_DTSDataPumpTask_2").CustomTask.RowsComplete = 0
before but it didnt work for me. Can you please help me out.
Thanks for ur help
January 2, 2007 at 1:39 pm
Can anyone please render any ideas and solutions on this. Thanks a lot for the help
November 15, 2007 at 6:39 am
'**********************************************************************
' Visual Basic ActiveX Script
'************************************************************************
Function Main()
Dim strExecPkgTask'Execute Package Task Name
strExecPkgTask = "DTSTask_DTSDataPumpTask_1"
Call SetPackageParams(DTSGlobalVariables.Parent.Tasks(Cstr(strExecPkgTask)).CustomTask)
Main = DTSTaskExecResult_Success
End Function
Sub SetPackageParams(objPkg)
msgbox(objPkg.RowsComplete)
End Sub
try this one it will show you the rowsaffected
Viewing 12 posts - 16 through 26 (of 26 total)
You must be logged in to reply to this topic. Login to reply