How to render image in HTML reports?
I have a webapp which invokes Reporting Services web service to generate
reports in HTML format. The reports are for internet users - the image is not
accessible to these internet users because they cannot access the report
server directly which is in the intranet. Is there a solution to this problem
at all?
Thanks
SanjayYes, although it is not simple. You need to use the RenderStream method to
get the image and put it in a place where it is available to the Internet
users. You need to pass this path into the initial Render() call using the
<StreamRoot> deviceInfo.
For what it is worth, this will be much easier in SQL 2005 RS.
--
Brian Welcker
Group Program Manager
Microsoft SQL Server
This posting is provided "AS IS" with no warranties, and confers no rights.
"Sanjay" <Sanjay@.discussions.microsoft.com> wrote in message
news:1A5971D1-5DB8-4B28-8AB1-38DFC1E1C25D@.microsoft.com...
> How to render image in HTML reports?
> I have a webapp which invokes Reporting Services web service to generate
> reports in HTML format. The reports are for internet users - the image is
> not
> accessible to these internet users because they cannot access the report
> server directly which is in the intranet. Is there a solution to this
> problem
> at all?
> Thanks
> Sanjay|||That works for me for the intranet users but not for the internet users
because the location where I can generate the image with RenderStream is not
available on internet.
Including an External Web image could work for me because I'm including the
same banner image in my reports, but when I tried to include an External Web
Image like
http://msdn.microsoft.com/library/toolbar/3.0/images/banners/msdn_masthead_ltr.gif
in my report in report designer, I got message 'Invalid Image'. Is that
expected or is it because of some restrictions in my environment?
Thanks
Sanjay
"Brian Welcker [MS]" wrote:
> Yes, although it is not simple. You need to use the RenderStream method to
> get the image and put it in a place where it is available to the Internet
> users. You need to pass this path into the initial Render() call using the
> <StreamRoot> deviceInfo.
> For what it is worth, this will be much easier in SQL 2005 RS.
> --
> Brian Welcker
> Group Program Manager
> Microsoft SQL Server
> This posting is provided "AS IS" with no warranties, and confers no rights.
>
> "Sanjay" <Sanjay@.discussions.microsoft.com> wrote in message
> news:1A5971D1-5DB8-4B28-8AB1-38DFC1E1C25D@.microsoft.com...
> > How to render image in HTML reports?
> > I have a webapp which invokes Reporting Services web service to generate
> > reports in HTML format. The reports are for internet users - the image is
> > not
> > accessible to these internet users because they cannot access the report
> > server directly which is in the intranet. Is there a solution to this
> > problem
> > at all?
> >
> > Thanks
> > Sanjay
>
>|||All images in the reports are effectively "internal". URL only means that
the Report Server retrieves the image from a URL. We need to actually store
the image for consistency (caching, snapshots, etc.). We don't have a 'late
bound' image.
I don't understand why you can't copy the image to a directory on the
external web site.
--
Brian Welcker
Group Program Manager
Microsoft SQL Server
This posting is provided "AS IS" with no warranties, and confers no rights.
"Sanjay" <Sanjay@.discussions.microsoft.com> wrote in message
news:FEC10F8E-F9C2-4938-9F16-3E3565EA723C@.microsoft.com...
> That works for me for the intranet users but not for the internet users
> because the location where I can generate the image with RenderStream is
> not
> available on internet.
> Including an External Web image could work for me because I'm including
> the
> same banner image in my reports, but when I tried to include an External
> Web
> Image like
> http://msdn.microsoft.com/library/toolbar/3.0/images/banners/msdn_masthead_ltr.gif
> in my report in report designer, I got message 'Invalid Image'. Is that
> expected or is it because of some restrictions in my environment?
> Thanks
> Sanjay
> "Brian Welcker [MS]" wrote:
>> Yes, although it is not simple. You need to use the RenderStream method
>> to
>> get the image and put it in a place where it is available to the Internet
>> users. You need to pass this path into the initial Render() call using
>> the
>> <StreamRoot> deviceInfo.
>> For what it is worth, this will be much easier in SQL 2005 RS.
>> --
>> Brian Welcker
>> Group Program Manager
>> Microsoft SQL Server
>> This posting is provided "AS IS" with no warranties, and confers no
>> rights.
>>
>> "Sanjay" <Sanjay@.discussions.microsoft.com> wrote in message
>> news:1A5971D1-5DB8-4B28-8AB1-38DFC1E1C25D@.microsoft.com...
>> > How to render image in HTML reports?
>> > I have a webapp which invokes Reporting Services web service to
>> > generate
>> > reports in HTML format. The reports are for internet users - the image
>> > is
>> > not
>> > accessible to these internet users because they cannot access the
>> > report
>> > server directly which is in the intranet. Is there a solution to this
>> > problem
>> > at all?
>> >
>> > Thanks
>> > Sanjay
>>|||I can't copy the image to a directory on the external web site because I
don't have access to the report server from the external web site machine as
a result of which I have an intermediate ReportsGeneratorService sitting in
the intranet which generates the reports. In addition I don't have access to
create image files on the external web site machine from the intranet-sitting
ReportsGeneratorService. For Security Reasons. Any suggestions?
Can I manipulate the HTML on the external web-site to pick up the images
from a location in the external web-site?
"Brian Welcker [MS]" wrote:
> All images in the reports are effectively "internal". URL only means that
> the Report Server retrieves the image from a URL. We need to actually store
> the image for consistency (caching, snapshots, etc.). We don't have a 'late
> bound' image.
> I don't understand why you can't copy the image to a directory on the
> external web site.
> --
> Brian Welcker
> Group Program Manager
> Microsoft SQL Server
> This posting is provided "AS IS" with no warranties, and confers no rights.
> "Sanjay" <Sanjay@.discussions.microsoft.com> wrote in message
> news:FEC10F8E-F9C2-4938-9F16-3E3565EA723C@.microsoft.com...
> > That works for me for the intranet users but not for the internet users
> > because the location where I can generate the image with RenderStream is
> > not
> > available on internet.
> > Including an External Web image could work for me because I'm including
> > the
> > same banner image in my reports, but when I tried to include an External
> > Web
> > Image like
> > http://msdn.microsoft.com/library/toolbar/3.0/images/banners/msdn_masthead_ltr.gif
> > in my report in report designer, I got message 'Invalid Image'. Is that
> > expected or is it because of some restrictions in my environment?
> >
> > Thanks
> > Sanjay
> > "Brian Welcker [MS]" wrote:
> >
> >> Yes, although it is not simple. You need to use the RenderStream method
> >> to
> >> get the image and put it in a place where it is available to the Internet
> >> users. You need to pass this path into the initial Render() call using
> >> the
> >> <StreamRoot> deviceInfo.
> >>
> >> For what it is worth, this will be much easier in SQL 2005 RS.
> >>
> >> --
> >> Brian Welcker
> >> Group Program Manager
> >> Microsoft SQL Server
> >>
> >> This posting is provided "AS IS" with no warranties, and confers no
> >> rights.
> >>
> >>
> >> "Sanjay" <Sanjay@.discussions.microsoft.com> wrote in message
> >> news:1A5971D1-5DB8-4B28-8AB1-38DFC1E1C25D@.microsoft.com...
> >> > How to render image in HTML reports?
> >> > I have a webapp which invokes Reporting Services web service to
> >> > generate
> >> > reports in HTML format. The reports are for internet users - the image
> >> > is
> >> > not
> >> > accessible to these internet users because they cannot access the
> >> > report
> >> > server directly which is in the intranet. Is there a solution to this
> >> > problem
> >> > at all?
> >> >
> >> > Thanks
> >> > Sanjay
> >>
> >>
> >>
>
>|||Yes, this is what StreamRoot is for. You can put whatever location you want
for picking up the images in the report.
--
Brian Welcker
Group Program Manager
Microsoft SQL Server
This posting is provided "AS IS" with no warranties, and confers no rights.
"Sanjay" <Sanjay@.discussions.microsoft.com> wrote in message
news:23B5C014-89AB-41AA-8A33-C9CA8381D0AB@.microsoft.com...
>I can't copy the image to a directory on the external web site because I
> don't have access to the report server from the external web site machine
> as
> a result of which I have an intermediate ReportsGeneratorService sitting
> in
> the intranet which generates the reports. In addition I don't have access
> to
> create image files on the external web site machine from the
> intranet-sitting
> ReportsGeneratorService. For Security Reasons. Any suggestions?
> Can I manipulate the HTML on the external web-site to pick up the images
> from a location in the external web-site?
> "Brian Welcker [MS]" wrote:
>> All images in the reports are effectively "internal". URL only means that
>> the Report Server retrieves the image from a URL. We need to actually
>> store
>> the image for consistency (caching, snapshots, etc.). We don't have a
>> 'late
>> bound' image.
>> I don't understand why you can't copy the image to a directory on the
>> external web site.
>> --
>> Brian Welcker
>> Group Program Manager
>> Microsoft SQL Server
>> This posting is provided "AS IS" with no warranties, and confers no
>> rights.
>> "Sanjay" <Sanjay@.discussions.microsoft.com> wrote in message
>> news:FEC10F8E-F9C2-4938-9F16-3E3565EA723C@.microsoft.com...
>> > That works for me for the intranet users but not for the internet users
>> > because the location where I can generate the image with RenderStream
>> > is
>> > not
>> > available on internet.
>> > Including an External Web image could work for me because I'm including
>> > the
>> > same banner image in my reports, but when I tried to include an
>> > External
>> > Web
>> > Image like
>> > http://msdn.microsoft.com/library/toolbar/3.0/images/banners/msdn_masthead_ltr.gif
>> > in my report in report designer, I got message 'Invalid Image'. Is that
>> > expected or is it because of some restrictions in my environment?
>> >
>> > Thanks
>> > Sanjay
>> > "Brian Welcker [MS]" wrote:
>> >
>> >> Yes, although it is not simple. You need to use the RenderStream
>> >> method
>> >> to
>> >> get the image and put it in a place where it is available to the
>> >> Internet
>> >> users. You need to pass this path into the initial Render() call using
>> >> the
>> >> <StreamRoot> deviceInfo.
>> >>
>> >> For what it is worth, this will be much easier in SQL 2005 RS.
>> >>
>> >> --
>> >> Brian Welcker
>> >> Group Program Manager
>> >> Microsoft SQL Server
>> >>
>> >> This posting is provided "AS IS" with no warranties, and confers no
>> >> rights.
>> >>
>> >>
>> >> "Sanjay" <Sanjay@.discussions.microsoft.com> wrote in message
>> >> news:1A5971D1-5DB8-4B28-8AB1-38DFC1E1C25D@.microsoft.com...
>> >> > How to render image in HTML reports?
>> >> > I have a webapp which invokes Reporting Services web service to
>> >> > generate
>> >> > reports in HTML format. The reports are for internet users - the
>> >> > image
>> >> > is
>> >> > not
>> >> > accessible to these internet users because they cannot access the
>> >> > report
>> >> > server directly which is in the intranet. Is there a solution to
>> >> > this
>> >> > problem
>> >> > at all?
>> >> >
>> >> > Thanks
>> >> > Sanjay
>> >>
>> >>
>> >>
>>
Showing posts with label generate. Show all posts
Showing posts with label generate. Show all posts
Wednesday, March 28, 2012
Monday, March 19, 2012
I'm newbie. Script to generate scripts (add job steps).
Hi, I want to add to my 50 single step jobs a second step with command
"execute JOB_STEP_FAIL <jobname>" where <jobname> is job name from sysjobs
table.
I want to use sp_add_jobstep .
I do not want to make this job by hand.
Thanks !!!!!!!!!!!!!!!!!!!!!!!!!!If you have a way to identify the 50 Jobs you want to add a step to, then us
e
a cursor, or table variable, or while loop, to run sp_add_jobstep for each
one...
Say the job names all start with 'DD'
Then
Select Job_id
From msdb..sysjobs
Where name like 'DD%'
Will give you list of all jobs
Then you can use a while loop
Declare @.JobName varChar(200) Set @.JobName = ''
While Exists (Select * From msdb..sysJobs
Where name like 'DD%'
And name > @.JobName)
Begin
Select @.JobName = Min(name )
From msdb..sysJobs
Where name like 'DD%'
And name > @.JobName
-- --
Exec sp_Add_Job_Step
@.job_name = @.JobName,
@.step_id = 2,
@.Step_Name = 'FailStep',
@.subsystem = 'TSQL',
@.command = 'execute JOB_STEP_FAIL ' + @.JobName
End
But if <jobName> in your post is just the same job that just failed, it
looks like you are trying to reattempt the same job if it gets to this step,
But there is both a ReAttempt , and a Fail method on each jobStep that are
more appropriate for this purpose... You should investigate those
"andrea favero" wrote:
> Hi, I want to add to my 50 single step jobs a second step with command
> "execute JOB_STEP_FAIL <jobname>" where <jobname> is job name from sysjob
s
> table.
> I want to use sp_add_jobstep .
> I do not want to make this job by hand.
> Thanks !!!!!!!!!!!!!!!!!!!!!!!!!!|||Thanks a lot for your fast answer.
Thanks
"CBretana" wrote:
> If you have a way to identify the 50 Jobs you want to add a step to, then
use
> a cursor, or table variable, or while loop, to run sp_add_jobstep for each
> one...
> Say the job names all start with 'DD'
> Then
> Select Job_id
> From msdb..sysjobs
> Where name like 'DD%'
> Will give you list of all jobs
> Then you can use a while loop
> Declare @.JobName varChar(200) Set @.JobName = ''
> While Exists (Select * From msdb..sysJobs
> Where name like 'DD%'
> And name > @.JobName)
> Begin
> Select @.JobName = Min(name )
> From msdb..sysJobs
> Where name like 'DD%'
> And name > @.JobName
> -- --
> Exec sp_Add_Job_Step
> @.job_name = @.JobName,
> @.step_id = 2,
> @.Step_Name = 'FailStep',
> @.subsystem = 'TSQL',
> @.command = 'execute JOB_STEP_FAIL ' + @.JobName
> End
>
> But if <jobName> in your post is just the same job that just failed, it
> looks like you are trying to reattempt the same job if it gets to this ste
p,
> But there is both a ReAttempt , and a Fail method on each jobStep that are
> more appropriate for this purpose... You should investigate those
>
> "andrea favero" wrote:
>
"execute JOB_STEP_FAIL <jobname>" where <jobname> is job name from sysjobs
table.
I want to use sp_add_jobstep .
I do not want to make this job by hand.
Thanks !!!!!!!!!!!!!!!!!!!!!!!!!!If you have a way to identify the 50 Jobs you want to add a step to, then us
e
a cursor, or table variable, or while loop, to run sp_add_jobstep for each
one...
Say the job names all start with 'DD'
Then
Select Job_id
From msdb..sysjobs
Where name like 'DD%'
Will give you list of all jobs
Then you can use a while loop
Declare @.JobName varChar(200) Set @.JobName = ''
While Exists (Select * From msdb..sysJobs
Where name like 'DD%'
And name > @.JobName)
Begin
Select @.JobName = Min(name )
From msdb..sysJobs
Where name like 'DD%'
And name > @.JobName
-- --
Exec sp_Add_Job_Step
@.job_name = @.JobName,
@.step_id = 2,
@.Step_Name = 'FailStep',
@.subsystem = 'TSQL',
@.command = 'execute JOB_STEP_FAIL ' + @.JobName
End
But if <jobName> in your post is just the same job that just failed, it
looks like you are trying to reattempt the same job if it gets to this step,
But there is both a ReAttempt , and a Fail method on each jobStep that are
more appropriate for this purpose... You should investigate those
"andrea favero" wrote:
> Hi, I want to add to my 50 single step jobs a second step with command
> "execute JOB_STEP_FAIL <jobname>" where <jobname> is job name from sysjob
s
> table.
> I want to use sp_add_jobstep .
> I do not want to make this job by hand.
> Thanks !!!!!!!!!!!!!!!!!!!!!!!!!!|||Thanks a lot for your fast answer.
Thanks
"CBretana" wrote:
> If you have a way to identify the 50 Jobs you want to add a step to, then
use
> a cursor, or table variable, or while loop, to run sp_add_jobstep for each
> one...
> Say the job names all start with 'DD'
> Then
> Select Job_id
> From msdb..sysjobs
> Where name like 'DD%'
> Will give you list of all jobs
> Then you can use a while loop
> Declare @.JobName varChar(200) Set @.JobName = ''
> While Exists (Select * From msdb..sysJobs
> Where name like 'DD%'
> And name > @.JobName)
> Begin
> Select @.JobName = Min(name )
> From msdb..sysJobs
> Where name like 'DD%'
> And name > @.JobName
> -- --
> Exec sp_Add_Job_Step
> @.job_name = @.JobName,
> @.step_id = 2,
> @.Step_Name = 'FailStep',
> @.subsystem = 'TSQL',
> @.command = 'execute JOB_STEP_FAIL ' + @.JobName
> End
>
> But if <jobName> in your post is just the same job that just failed, it
> looks like you are trying to reattempt the same job if it gets to this ste
p,
> But there is both a ReAttempt , and a Fail method on each jobStep that are
> more appropriate for this purpose... You should investigate those
>
> "andrea favero" wrote:
>
Subscribe to:
Posts (Atom)