Showing posts with label invoke. Show all posts
Showing posts with label invoke. Show all posts

Friday, March 30, 2012

Invoking SSIS Packages from DotNet

Hi,

How can we invoke SSIS Packages from an Windows or ASP.NET Application (using C# ).

Thanks

Jegan

First you have a look at the documentation -

ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/dtsref9/html/1a08c75e-ce8c-45ee-81bd-32248bbdb2b2.htm

or

Managing Packages Programmatically
(http://msdn2.microsoft.com/en-us/library/1a08c75e-ce8c-45ee-81bd-32248bbdb2b2.aspx)

Then you ask some specific questions if you get stuck.

|||

Darren ,

Thanks for the links. now i am able to create sample application.but when i am using Fuzzylookup and FlatFileDestination in my package and i am executing the package from a windows application (C#).i am getting the following errors

1.The product level is insufficient for component Fuzzy Lookup
2.The product level is insufficient for component Conditional Split
3.The product level is insufficient for component Flat File

what could be the reason .

Thanks

Jegan

|||

Fuzzy Lookup requires installation of SSIS from Enterprise Edition of SQL Server, for other components SSIS installation from Standard Edition is OK. You've probably only installed the Client/Workstation Componentss, not SSIS - so you can't run the packages.

For more details see http://msdn2.microsoft.com/en-us/library/aa337371.aspx

|||

Michael,

my machine already have SSIS installed and i am using VS 2005 Team Edition for Software Developers.so what could be the problem

Thanks

Jegan

|||Check if you have a service called MsDtsServer (display name SQL Server Integration Services).

If you do not have such service, you don't have SSIS installed. Installing just Workstation Components gives you access to some SSIS aspects, e.g. designing the packages in BIDS. But it is not enough to execute the packages outside of designer.

Invoking SSIS Packages from DotNet

Hi,

How can we invoke SSIS Packages from an Windows or ASP.NET Application (using C# ).

Thanks

Jegan

First you have a look at the documentation -

ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/dtsref9/html/1a08c75e-ce8c-45ee-81bd-32248bbdb2b2.htm

or

Managing Packages Programmatically
(http://msdn2.microsoft.com/en-us/library/1a08c75e-ce8c-45ee-81bd-32248bbdb2b2.aspx)

Then you ask some specific questions if you get stuck.

|||

Darren ,

Thanks for the links. now i am able to create sample application.but when i am using Fuzzylookup and FlatFileDestination in my package and i am executing the package from a windows application (C#).i am getting the following errors

1.The product level is insufficient for component Fuzzy Lookup
2.The product level is insufficient for component Conditional Split
3.The product level is insufficient for component Flat File

what could be the reason .

Thanks

Jegan

|||

Fuzzy Lookup requires installation of SSIS from Enterprise Edition of SQL Server, for other components SSIS installation from Standard Edition is OK. You've probably only installed the Client/Workstation Componentss, not SSIS - so you can't run the packages.

For more details see http://msdn2.microsoft.com/en-us/library/aa337371.aspx

|||

Michael,

my machine already have SSIS installed and i am using VS 2005 Team Edition for Software Developers.so what could be the problem

Thanks

Jegan

|||Check if you have a service called MsDtsServer (display name SQL Server Integration Services).

If you do not have such service, you don't have SSIS installed. Installing just Workstation Components gives you access to some SSIS aspects, e.g. designing the packages in BIDS. But it is not enough to execute the packages outside of designer.sql

Invoking a service on firing a trigger

Hi

Im trying to invoke a .Net service when a trigger is fired on a table in SQL Server 2000.

The service is working fine but I need to invoke it when the trigger is fired. How can I achieve this?

Hi!

At first, why do you think your problem is concern with SQL-NS? The second: does you question relate to SQL Server 2005? You have wrote, that the trigger on SQL Server 2000 invokes the service and the services works well.

Then, what do you mean by saying "invokes"? Does the trigger start the service or it just send a message to him?

Invoking a service on firing a trigger

Hi

Im trying to invoke a .Net service when a trigger is fired on a table in SQL Server 2000.

The service is working fine but I need to invoke it when the trigger is fired. How can I achieve this?

Hi!

At first, why do you think your problem is concern with SQL-NS? The second: does you question relate to SQL Server 2005? You have wrote, that the trigger on SQL Server 2000 invokes the service and the services works well.

Then, what do you mean by saying "invokes"? Does the trigger start the service or it just send a message to him?

Invoking a batch file from Report

Hi !

I have to invoke a batch file (.bat) when an ad-hoc report is executed. I've currently written a .Net code for invoking (using System.Diagnostics.Process) the batch file. The rdl file calls the method.

When I run the report from Report Designer the batch file is getting executed. But if I deploy it in the Reporting Server and run the report through Web Interface the batch file is not getting executed.

Looks like some security issue. Can someone provide a solution for this?

Thanks.

Where did you place the batch file ? All commands executed either in Script or custom code or executed on the server not on the client.

Jens K. Suessmeyer.


http://www.sqlserver2005.de

|||Just a suggestion on how to execute the .bat file. Could′t you use a SQL Agent job instead and call sp_start_job from a dataset in the report?|||

Hi Jens,

Thanks for the reply.

I placed the batch file in the server. I also moved the code (to invoke a batch file using System.Diagnostics.Process class) to a VB.Net dll and tried invoking the function from the rdl. The function is not getting invoked. I also added SecurityPermissionAttribute to the class. Is there any other Security permission that needs to be added for the code to be accessed.

Please find below the sample:

Public Shared Function fnRunSPX(ByVal x As String, ByVal y As String, ByVal z As String, ByVal w As String)

Dim Pro As New System.Diagnostics.Process

Dim Elog As New System.Diagnostics.EventLog

If Not Elog.SourceExists("BillingDateBatch") Then

Elog.CreateEventSource("BillingDateBatch", "Application")

End If

Dim EventLog1 As New System.Diagnostics.EventLog

EventLog1.Source = "BillingDateBatch"

EventLog1.Log = "Application"

EventLog1.WriteEntry("Success", System.Diagnostics.EventLogEntryType.SuccessAudit)

Pro.StartInfo.FileName = "C:\\batch.bat"

Pro.StartInfo.Arguments = x + " " + y + " " + z + " " + w

Pro.Start()

Pro.WaitForExit()

End Function

Even the evenlogging (present in teh above code) does not happen. Please let me know if you have any questions.

Thanks,

Aravind

Invoke 'Refresh fields' programmatically

Hi all
I've implemented our custom data processing extension for Reporting Services
and the 'Refresh Fields' button available in the Generic Query Designer is
very useful to us to make sure the fields in the RDL files are updated.
Unfortunately, I can't seem to find a way to programmatically invoke this
'Refresh Fields' command. I want to write my own utility, but I'm not an
expert in .NET nor XML. Any pointers or guidance on how to achieve my goal
is greatly appreciated!
Thanks!!Hi,
I'll see if I can find the answer. I'll update you once I have more
information.
Sincerely,
William Wang
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
This posting is provided "AS IS" with no warranties, and confers no rights.|||Thank you and your
"William Wang[MSFT]" wrote:
> Hi,
> I'll see if I can find the answer. I'll update you once I have more
> information.
> Sincerely,
> William Wang
> Microsoft Online Partner Support
> When responding to posts, please "Reply to Group" via your newsreader so
> that others may learn and benefit from your issue.
> This posting is provided "AS IS" with no warranties, and confers no rights.
>|||Hi,
You may want to implement the refresh logic externally by calling
IDbCommand.ExecuteReader(SchemaOnly). I suggest that you review this thread
for more information:
http://groups.google.com/group/microsoft.public.sqlserver.reportingsvcs/brow
se_thread/thread/d4a878f340785d77/ae765089b645dc3a?lnk=st&q=%22refresh+field
s%22+SchemaOnly+group:microsoft.public.sqlserver.reportingsvcs&rnum=5&hl=en#
ae765089b645dc3a
Sincerely,
William Wang
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
This posting is provided "AS IS" with no warranties, and confers no rights.|||Thanks for the info. It's helpful to know what exactly happens for 'Refresh
Fields' behind the scene.
Unfortunately my main goal is to update the given RDL file(s). Everytime I
clicked the 'Refresh Fields' button the corresponding RDL file gets updated,
which is what I'm looking for.
In a Reporting Project, I want to be able to programmatically refresh all
its RDL files. Maybe I should ask how to get access to an IDbCommand object
for each report?
Your help is appreciated!! Thanks!
Jenny
"William Wang[MSFT]" wrote:
> Hi,
> You may want to implement the refresh logic externally by calling
> IDbCommand.ExecuteReader(SchemaOnly). I suggest that you review this thread
> for more information:
> http://groups.google.com/group/microsoft.public.sqlserver.reportingsvcs/brow
> se_thread/thread/d4a878f340785d77/ae765089b645dc3a?lnk=st&q=%22refresh+field
> s%22+SchemaOnly+group:microsoft.public.sqlserver.reportingsvcs&rnum=5&hl=en#
> ae765089b645dc3a
> Sincerely,
> William Wang
> Microsoft Online Partner Support
> When responding to posts, please "Reply to Group" via your newsreader so
> that others may learn and benefit from your issue.
> This posting is provided "AS IS" with no warranties, and confers no rights.
>|||There's not a direct way so far.
<yinjennytam@.newsgroup.nospam> wrote in message
news:28AD35DA-113D-43C3-B95A-50C910D01CD8@.microsoft.com...
> Thanks for the info. It's helpful to know what exactly happens for
> 'Refresh
> Fields' behind the scene.
> Unfortunately my main goal is to update the given RDL file(s). Everytime
> I
> clicked the 'Refresh Fields' button the corresponding RDL file gets
> updated,
> which is what I'm looking for.
> In a Reporting Project, I want to be able to programmatically refresh all
> its RDL files. Maybe I should ask how to get access to an IDbCommand
> object
> for each report?
> Your help is appreciated!! Thanks!
> Jenny
>
> "William Wang[MSFT]" wrote:
>> Hi,
>> You may want to implement the refresh logic externally by calling
>> IDbCommand.ExecuteReader(SchemaOnly). I suggest that you review this
>> thread
>> for more information:
>> http://groups.google.com/group/microsoft.public.sqlserver.reportingsvcs/brow
>> se_thread/thread/d4a878f340785d77/ae765089b645dc3a?lnk=st&q=%22refresh+field
>> s%22+SchemaOnly+group:microsoft.public.sqlserver.reportingsvcs&rnum=5&hl=en#
>> ae765089b645dc3a
>> Sincerely,
>> William Wang
>> Microsoft Online Partner Support
>> When responding to posts, please "Reply to Group" via your newsreader so
>> that others may learn and benefit from your issue.
>> This posting is provided "AS IS" with no warranties, and confers no
>> rights.
>>

Invoke or detect Print Report event

Hi
I'm not sure if this is possible, but hoping that someone out there can
give some guidance.
I'm using a reporting services ReportViewer object to view reports via
an ASP.NET application. I've just upgraded to SP2 to make use of the
print functionality.
However a requirement i have is that a particular report can be printed
only once. Is there a way that i can tap into the Print Report button
event so that i can detect if the print button has been clicked?
Or alternatively is there a way i can invoke the print method from
within ASP.NET aplication?
Or maybe there is some other way to do this....all suggestions
welcome!!!!!!!
Many many thanks in advance
Cheers!!!!There is no way to do this that I know of. And what counts as once? What if
they open up IE again and view the report again? How would you know that it
is the first or second time?
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"muirboy" <gmuir@.statestreet.com> wrote in message
news:1157040604.891636.111600@.m73g2000cwd.googlegroups.com...
> Hi
> I'm not sure if this is possible, but hoping that someone out there can
> give some guidance.
> I'm using a reporting services ReportViewer object to view reports via
> an ASP.NET application. I've just upgraded to SP2 to make use of the
> print functionality.
> However a requirement i have is that a particular report can be printed
> only once. Is there a way that i can tap into the Print Report button
> event so that i can detect if the print button has been clicked?
> Or alternatively is there a way i can invoke the print method from
> within ASP.NET aplication?
> Or maybe there is some other way to do this....all suggestions
> welcome!!!!!!!
> Many many thanks in advance
> Cheers!!!!
>|||Bruce
They should be able to view it as many times as they want, therefore
coming out of IE and back in again would be fine. Essentially once
someone had clicked on the print button it would go back to the DB to
say that the report has been printed, thus locking it for anyone else.
If this sounds bizarre, its due a requirement from an external company
that only one print out should exist. There is a 'duplicate' function
which gives the user access to print the same report again, however the
word 'duplicate' would be splashed over to signify it is not the
original
So are you saying there's no way for me to detect the print function
has been invoked?
Thanks
Bruce L-C [MVP] wrote:
> There is no way to do this that I know of. And what counts as once? What if
> they open up IE again and view the report again? How would you know that it
> is the first or second time?
>|||It is a client side active X control. If you were to detect it, it would
have to be via script and I just don't know. From RS perspective it is just
another rendering request for the report. What about exporting to PDF?
Unless you turn off exporting to PDF (which cannot be done by report, only
for the complete server) then all the user has to do is export to PDF and
print (which is what my users used to do before they adding printing).
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"muirboy" <gmuir@.statestreet.com> wrote in message
news:1157044757.246385.151290@.74g2000cwt.googlegroups.com...
> Bruce
> They should be able to view it as many times as they want, therefore
> coming out of IE and back in again would be fine. Essentially once
> someone had clicked on the print button it would go back to the DB to
> say that the report has been printed, thus locking it for anyone else.
> If this sounds bizarre, its due a requirement from an external company
> that only one print out should exist. There is a 'duplicate' function
> which gives the user access to print the same report again, however the
> word 'duplicate' would be splashed over to signify it is not the
> original
> So are you saying there's no way for me to detect the print function
> has been invoked?
> Thanks
> Bruce L-C [MVP] wrote:
>> There is no way to do this that I know of. And what counts as once? What
>> if
>> they open up IE again and view the report again? How would you know that
>> it
>> is the first or second time?
>>
>

Invoke a call for a report in VB2003

We just updated to SQL2005 and all it entails. I've made a report,
deployed it and published it on the web reportserver. My question is,
how do I call it in a VB2003 application? I know how to migrate the
apps in the new "DTS". I can find all the info I need on VB2005, but
we didn't upgrade to that. I need to be able to print this report
during our down time. So, if calling it in 2003 isn't an option, is
there anyway I can schedule the report to print. I see scheduling, but
that's just to compile the report, not print it(unless I'm missing
something). Any help is greatly appreciated. Thanks!Printing is client oriented in both RS 2000 and RS 2005. No difference
between these two. What you could do is schedule a job to render to a file,
pdf format and then have an app monitoring the directory, picking up the
file and printing it.
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"MBE" <nada@.knology.net> wrote in message
news:1157724090.595634.194360@.i3g2000cwc.googlegroups.com...
> We just updated to SQL2005 and all it entails. I've made a report,
> deployed it and published it on the web reportserver. My question is,
> how do I call it in a VB2003 application? I know how to migrate the
> apps in the new "DTS". I can find all the info I need on VB2005, but
> we didn't upgrade to that. I need to be able to print this report
> during our down time. So, if calling it in 2003 isn't an option, is
> there anyway I can schedule the report to print. I see scheduling, but
> that's just to compile the report, not print it(unless I'm missing
> something). Any help is greatly appreciated. Thanks!
>|||That makes sense. I'll work on it and see what happens. Thanks! I
guess I've been struggling learning Reporting Services that I made it
harder than it was. Thanks again.
Bruce L-C [MVP] wrote:
> Printing is client oriented in both RS 2000 and RS 2005. No difference
> between these two. What you could do is schedule a job to render to a file,
> pdf format and then have an app monitoring the directory, picking up the
> file and printing it.
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
>
> "MBE" <nada@.knology.net> wrote in message
> news:1157724090.595634.194360@.i3g2000cwc.googlegroups.com...
> > We just updated to SQL2005 and all it entails. I've made a report,
> > deployed it and published it on the web reportserver. My question is,
> > how do I call it in a VB2003 application? I know how to migrate the
> > apps in the new "DTS". I can find all the info I need on VB2005, but
> > we didn't upgrade to that. I need to be able to print this report
> > during our down time. So, if calling it in 2003 isn't an option, is
> > there anyway I can schedule the report to print. I see scheduling, but
> > that's just to compile the report, not print it(unless I'm missing
> > something). Any help is greatly appreciated. Thanks!
> >