Showing posts with label asp. Show all posts
Showing posts with label asp. Show all posts

Thursday, March 29, 2012

calling stored procedure in VC++

i have a stored procedure to get the user pin.
the stored procedure works perfectly as i tested it both in VB and ASP,
but when i try to call stored procedure from VC++, then i get a
Idispatch error #3092.
here is the code:

BSTR newpin;
_bstr_t qsql = "{call user.getpin(?,{resultset 100,pin})}";
command->PutActiveConnection(conn);
command->PutCommandText(qsql);
command->Parameters->Refresh();
command->Parameters->Item[_variant_t((short)0)]->Value = userid;
rst = command->Execute(NULL,NULL,adCmdText);
if(rst->RecordCount > 0)
{
newpin = rst->Fields->GetItem((short)0)->GetValue();

}

is there any problem with this code.
thanks
Can you provide more complete sample including code for creating stored procedure? Are you sure about syntax "{call user.getpin(?,{resultset 100,pin})}";? Also which line of code throws the exception? BWT RecordCount may be 0 but

rst->Fields->GetItem((short)0)->GetValue();

may still return correct value. Also have you tried PutRefActiveConnection instead? It's difficult to say without more information.

Tuesday, March 27, 2012

Calling Stored Procedure from ASP-Problem

I am having a problem to execute a stored procedure from ASP.

I have created several stored procedure(SP) and everything works fine from ASP except 3 of my StoredProcedures.

This SP has an INSERT Statement where the SELECT query has couple of joins to master tables. When I run this StoredProcedure (SP) in the server using Queryanalyser, it takes nearly 30 seconds to complete, and it runs without any problems.

When I execute this SP from ASP like any other SPs, procedure starts and it doesnot complete the INSERT statement. ASP dosnot raise any errors, i checked for error messages and no errors. I don't know whats going on..?
I also observerd that, SPs which was failing was taking more than 30 seconds to complete when I run from the Server, and all other SPs which was running ok was taking less than 20 seconds. So is there any settings in the ADODB connection? or any other settings in ASP?

Please help

-IshBy default ASP times out after 30 seconds. Talk to your webmaster or network admin about increasing the timeout period. Better yet, if you can, optimize the stored procedure to run faster.

Richard

Originally posted by Ishwara Marakaj
I am having a problem to execute a stored procedure from ASP.

I have created several stored procedure(SP) and everything works fine from ASP except 3 of my StoredProcedures.

This SP has an INSERT Statement where the SELECT query has couple of joins to master tables. When I run this StoredProcedure (SP) in the server using Queryanalyser, it takes nearly 30 seconds to complete, and it runs without any problems.

When I execute this SP from ASP like any other SPs, procedure starts and it doesnot complete the INSERT statement. ASP dosnot raise any errors, i checked for error messages and no errors. I don't know whats going on..?
I also observerd that, SPs which was failing was taking more than 30 seconds to complete when I run from the Server, and all other SPs which was running ok was taking less than 20 seconds. So is there any settings in the ADODB connection? or any other settings in ASP?

Please help

-Ish|||Originally posted by ambroser
By default ASP times out after 30 seconds. Talk to your webmaster or network admin about increasing the timeout period. Better yet, if you can, optimize the stored procedure to run faster.

Richard

ambroser,

Thanks for your reply. Are you talking about script timeout or session timeout? I already increased this timeout values in the server, but no luck.
When these stored procedures fails they don't raise any erros, they just don't execute, ASP continues and processes the next stored procedure. Basically i don't get any timeout errors.

Thanks
Ish

Calling Stored Procedure from asp without waiting

Hi,
I'm developping a asp application that somestimes needs some heavy
synchronisation done. I wrote a stored procedure for that purpose witch
takes approximatly 15 minutes. Right now I run this directly on the
server (using MS SQL Server management studio). But I would love to be
able to call it from a asp-page. But I don't want the asp script to
wait for 15 minutes before returning. I figured, it should be possible
to tell the stored procedure call that it should run on the server on
its own. Is this possible? And how? Are there better/other solutions?
Thnx for your time,
Anne SchuthIs this done once a day?
Maybe you should create a scheduled job
Denis the SQL Menace
http://sqlservercode.blogspot.com/|||Thnx for your reply.
No, I should have mentioned that. It's not done with a regular interval
at all.
Anne|||In ASP.Net you could use an asynchronous call.
If you create a job in SQL Server Agent, you could call a stored procedure
that starts the job. The stored procedure does not wait for the job to
finish, so neither does your ASP page.
"Anne" <anne.schuth@.gmail.com> wrote in message
news:1145632601.510533.45240@.z34g2000cwc.googlegroups.com...
> Hi,
> I'm developping a asp application that somestimes needs some heavy
> synchronisation done. I wrote a stored procedure for that purpose witch
> takes approximatly 15 minutes. Right now I run this directly on the
> server (using MS SQL Server management studio). But I would love to be
> able to call it from a asp-page. But I don't want the asp script to
> wait for 15 minutes before returning. I figured, it should be possible
> to tell the stored procedure call that it should run on the server on
> its own. Is this possible? And how? Are there better/other solutions?
> Thnx for your time,
> Anne Schuth
>|||is it asp.NET - in which case you want to use an asynchronous thread to
fire off the sp|||I would build an ASP page.. which called a stored procedure.
And that stored procedure would schedule a job (like 10 seconds into the
future) to run.. and that job would run a stored procedure which did your
15min of work.
uspFireOffTheJobWhichRunsTheMainStoredPr
ocedure
-- the contents of this stor proc would be
dbo.uspJobScheduleUpdate ( 'MyLongJob1' , 'JobSchedule1ForMyLongJob1' , 20
uspLongRunningStoredProcedure
--the contents of this proc would be ... your code to do the 15 minutes or
work.
..
That was about 2 ws of my time (the stuff above and below), so post a
thank you... if you go this route.
Here is some code to help ,,, this would programmatically CREATE the job.
The 2 procedure above ... esp the uspFireOffxxxxx would be needed to
SCHEDULE the job
declare @.jobName varchar(128)
declare @.jobStepName varchar(128)
declare @.jobScheduleName varchar(128)
declare @.uspName varchar(128)
declare @.uuid uniqueidentifier
select @.jobName = 'MyLongJob1'
select @.uspName = 'dbo.uspLongRunningStoredProcedure'
select @.jobStepName = 'JobStep1For' + @.jobName
select @.jobScheduleName = 'JobSchedule1For' + @.jobName
select @.uspName = 'EXEC ' + @.uspName
declare @.serverName varchar(128)
select @.serverName = CONVERT(varchar(128) , SERVERPROPERTY('servername') )
--print @.serverName
declare @.dbName varchar(128)
select @.dbName = DB_NAME()
EXEC msdb.dbo.sp_add_job @.job_name = @.jobName,
@.enabled = 1,
@.description = @.jobName,
@.owner_login_name = 'sa' -- << THIS ONE YOU NEED TO WATCH .. and use
the loginname that your asp page uses to connect to the db()
EXEC msdb.dbo.sp_add_jobstep @.job_name = @.jobName,
@.step_name = @.jobStepName,
@.subsystem = 'TSQL',
@.database_name = @.dbName ,
@.command = @.uspName
EXEC msdb.dbo.sp_add_jobserver @.job_name = @.jobName,
@.server_name = @.serverName
-- END create jobs programatically
here is a final script.. I created to update the schedule on a job .. by
using its name, schedueName and delay seconds.
in my testing I found 10 seconds was the smallest increment I could use.
if exists (select * from sysobjects
where id = object_id('dbo.uspJobScheduleUpdate') and sysstat & 0xf = 4)
drop procedure dbo.uspJobScheduleUpdate
GO
CREATE Procedure dbo.uspJobScheduleUpdate ( @.jobName varchar(128) ,
@.jobScheduleName varchar(128) , @.delaySeconds int )
AS
SET NOCOUNT ON
declare @.minimumTimeDelaySeconds int
Select @.minimumTimeDelaySeconds = 10
if @.delaySeconds < @.minimumTimeDelaySeconds
BEGIN
select @.delaySeconds = @.minimumTimeDelaySeconds
END
declare @.now datetime
select @.now = GETDATE()
Select @.now = DATEADD(s , @.delaySeconds , @.now)
--print @.now
--select DATEPART(s , @.now)
--select DATEPART(hh , @.now)
--select DATEPART(mi , @.now)
/*
[@.active_start_date =] active_start_date
Is the date on which execution of the job can begin. active_start_date is
int,
with a default of NULL. Values must be formatted as YYYYMMDD.
If active_start_date is not NULL, the date must be greater than or equal to
19900101.
*/
declare @.year varchar(4)
declare @.month varchar(2)
declare @.day varchar(2)
declare @.yearint int
declare @.monthint int
declare @.dayint int
declare @.hour varchar(2)
declare @.minute varchar(2)
declare @.second varchar(2)
declare @.hourint int
declare @.minuteint int
declare @.secondint int
--year does not need prefixed "0"
select @.yearint= DATEPART(yyyy , @.now)
select @.year = convert(varchar(4) , @.yearint )
select @.monthint= DATEPART(m , @.now)
if @.monthint < 10
BEGIN
select @.month = '0' + convert(varchar(1) , @.monthint )
END
else
BEGIN
select @.month = convert(varchar(2) , @.monthint )
END
select @.dayint= DATEPART(d , @.now)
if @.dayint < 10
BEGIN
select @.day = '0' + convert(varchar(1) , @.dayint )
END
else
BEGIN
select @.day = convert(varchar(2) , @.dayint )
END

select @.hourint= DATEPART(hh , @.now)
if @.hourint < 10
BEGIN
select @.hour = '0' + convert(varchar(1) , @.hourint )
END
else
BEGIN
select @.hour = convert(varchar(2) , @.hourint )
END
select @.minuteint= DATEPART(mi , @.now)
if @.minuteint < 10
BEGIN
select @.minute = '0' + convert(varchar(1) , @.minuteint )
END
else
BEGIN
select @.minute = convert(varchar(2) , @.minuteint )
END
select @.secondint= DATEPART(s , @.now)
if @.secondint < 10
BEGIN
select @.second = '0' + convert(varchar(1) , @.secondint )
END
else
BEGIN
select @.second = convert(varchar(2) , @.secondint )
END
--print '*' + @.hour + '*'
--print '*' + @.minute + '*'
--print '*' + @.second + '*'
declare @.derivedstartdate varchar(12)
select @.derivedstartdate = @.year + @.month + @.day
declare @.derivedstarttime varchar(12)
select @.derivedstarttime = @.hour + @.minute + @.second
--print @.derivedstartdate
--print @.derivedstarttime
declare @.alreadyExists bit
declare @.enabled bit
declare @.active_start_date int
declare @.active_start_time int
EXEC dbo.uspJobScheduleExists @.jobName , @.jobScheduleName , @.alreadyExists
output , @.enabled output , @.active_start_date output , @.active_start_time
output
/*
print 'Debugging Values'
print '@.jobName=' + @.jobName
print '@.jobScheduleName=' + @.jobScheduleName
print '@.alreadyExists=' + convert(varchar(8) , @.alreadyExists)
print '@.enabled=' + convert(varchar(8) , @.enabled)
print '@.active_start_date=' + convert(varchar(16) , @.active_start_date)
print '@.active_start_time=' + convert(varchar(16) , @.active_start_time)
print '/Debugging Values'
*/
declare @.jobSchedulingCheck int
if @.alreadyExists = 0 --FALSE
BEGIN
EXEC @.jobSchedulingCheck = msdb.dbo.sp_add_jobschedule
@.job_name = @.jobName,
@.name = @.jobScheduleName,
@.enabled = 1,
@.freq_type = 1 ,
@.freq_interval = 1 , --once
@.active_start_date = @.derivedstartdate ,
@.active_start_time = @.derivedstarttime--'153000' --(3:30 pm) 24hr HHMMSS.
END
else
BEGIN
declare @.allClearToUpdateTheJob bit
select @.allClearToUpdateTheJob = 1 -- default to true
if @.enabled <> 0 -- The job is enabled,,but how far in the future'
BEGIN
--most times, if its enabled..then its set to fire pretty quickly in the
future..so set it to false..but also check a "too far in the future" date
select @.allClearToUpdateTheJob = 0 -- false
--/*
if @.active_start_date - @.derivedstartdate >= 0 -- the date is in the future
..or today
begin
if @.active_start_time - @.derivedstarttime > @.delaySeconds -- the time is
greater in the future than the delay period
begin
--print 'too far into the future for the job!'
select @.allClearToUpdateTheJob = 1-- while it was enabled..it was too far
into the future
end
end
--*/
END
--if its not enabled, then the @.allClearToUpdateTheJob value will not
changed..thus it will be updated
if @.allClearToUpdateTheJob <> 0
BEGIN
EXEC @.jobSchedulingCheck = msdb.dbo.sp_update_jobschedule --0 (success) or 1
(failure)
@.job_name = @.jobName,
@.name = @.jobScheduleName,
@.enabled = 1,
@.freq_type = 1 ,
@.freq_interval = 1 , --once
@.active_start_date = @.derivedstartdate ,
@.active_start_time = @.derivedstarttime--'153000' --(3:30 pm) 24hr HHMMSS.
END
END
--Return Code Values
--0 (success) or 1 (failure)
if (@.jobSchedulingCheck<>0)
BEGIN
INSERT INTO dbo.tblAuditTrail (SubjectID , ObjectID , ShortDescription)
VALUES (@.jobName , @.jobScheduleName, 'sp_add_jobschedule or
sp_update_jobschedule FAILED.')
END
SELECT( @.jobSchedulingCheck )
if (@.jobSchedulingCheck IS NOT NULL)
begin
return @.jobSchedulingCheck
end
SET NOCOUNT OFF
GO
"Anne" <anne.schuth@.gmail.com> wrote in message
news:1145633124.959348.250700@.g10g2000cwb.googlegroups.com...
> Thnx for your reply.
> No, I should have mentioned that. It's not done with a regular interval
> at all.
> Anne
>|||Yeah, that does deserve a THANK YOU!
I will need some time to get it all together and running but this
certainly points me in the right direction! I've never used jobs
before, so din't think of it.
Thnx all for the quick replies!
(NP: I don't use asp.net)|||wow'
all that hour minute second stuff can be replace with
declare @.now datetime
select @.now = getdate()
select
convert(varchar,@.now,112),replace(conver
t(varchar,@.now,108),':','')
Denis the SQL Menace
http://sqlservercode.blogspot.com/|||If you are on 2005, consider using Service Broker for this.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Anne" <anne.schuth@.gmail.com> wrote in message
news:1145632601.510533.45240@.z34g2000cwc.googlegroups.com...
> Hi,
> I'm developping a asp application that somestimes needs some heavy
> synchronisation done. I wrote a stored procedure for that purpose witch
> takes approximatly 15 minutes. Right now I run this directly on the
> server (using MS SQL Server management studio). But I would love to be
> able to call it from a asp-page. But I don't want the asp script to
> wait for 15 minutes before returning. I figured, it should be possible
> to tell the stored procedure call that it should run on the server on
> its own. Is this possible? And how? Are there better/other solutions?
> Thnx for your time,
> Anne Schuth
>|||
Thanks,
I felt like what I was doing was too much drama when I wrote it.
I appreciate the convert tip.
SQL wrote:
> wow'
> all that hour minute second stuff can be replace with
> declare @.now datetime
> select @.now = getdate()
> select
> convert(varchar,@.now,112),replace(conver
t(varchar,@.now,108),':','')
>
> Denis the SQL Menace
> http://sqlservercode.blogspot.com/

Calling SQL Stored Procedure from ASP

Hi friends, i want to call a SP from ASP (not dot net) that returns some man
y
rows.
The conn string is:
<%
Set objCon = CreateObject("ADODB.Connection")
Set objRS = CreateObject("ADODB.Recordset")
objcon.connectionstring = "Provider=SQLOLEDB.1;User
ID=USER;Password=XXXX;Persist Security Info=True;Initial Catalog=opessa;Data
Source=SERVER01"
iCursorType = 1
iLockType = 3
objCon.Open
%>
Then i use the following sentence to call the SP from ASP
SQLtxt = "exec SPNAME '" & PARAM1 & "','" & PARAM2 & "','" & PARAM3 & "'"
objRS.open SQLTXT, objcon
And last, i try to print the results:
WHILE NOT ObjRS.EOF
Response.Write "" & ObjRS("XXXXX").VALUE & "" &
ObjRS("XXXXX").VALUE & "" & ObjRS("XXXXX").VALUE & " Mb" & "" &
ObjRS("XXXXX").VALUE & " Mb" & "" & ObjRS("XXXXX").VALUE & " %" & ""
ObjRS.Movenext
WEND
ObjRS.CLOSE
But i receive the following error:
ADODB.Recordset error '800a0e78'
Operation is not allowed when the object is closed.
Whats wrong? Anyone can help me?
Thanks in advance.Tincho wrote:
> Hi friends, i want to call a SP from ASP (not dot net) that returns
> some many rows.
Here is my canned reply on this topic:
http://groups.google.com/groups?hl=...FTNGP12.phx.gbl
Bob barrows
--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.|||I found the solution:
I forgot the command:
set nocount inside the stored_procedure.
Best regards!
"Bob Barrows [MVP]" wrote:

> Tincho wrote:
> Here is my canned reply on this topic:
> http://groups.google.com/groups?hl=...FTNGP12.phx.gbl
> Bob barrows
> --
> Microsoft MVP -- ASP/ASP.NET
> Please reply to the newsgroup. The email account listed in my From
> header is my spam trap, so I don't check it very often. You will get a
> quicker response by posting to the newsgroup.
>
>|||Make sure the stored procedure has SET NOCOUNT ON.
"Tincho" <Tincho@.discussions.microsoft.com> wrote in message
news:D15145D5-A0CF-4BA3-B211-6532936B1E92@.microsoft.com...
> Hi friends, i want to call a SP from ASP (not dot net) that returns some
> many
> rows.
> The conn string is:
> <%
> Set objCon = CreateObject("ADODB.Connection")
> Set objRS = CreateObject("ADODB.Recordset")
> objcon.connectionstring = "Provider=SQLOLEDB.1;User
> ID=USER;Password=XXXX;Persist Security Info=True;Initial
> Catalog=opessa;Data
> Source=SERVER01"
> iCursorType = 1
> iLockType = 3
> objCon.Open
> %>
> Then i use the following sentence to call the SP from ASP
> SQLtxt = "exec SPNAME '" & PARAM1 & "','" & PARAM2 & "','" & PARAM3 & "'"
> objRS.open SQLTXT, objcon
> And last, i try to print the results:
> WHILE NOT ObjRS.EOF
> Response.Write "" & ObjRS("XXXXX").VALUE & "" &
> ObjRS("XXXXX").VALUE & "" & ObjRS("XXXXX").VALUE & " Mb" & "" &
> ObjRS("XXXXX").VALUE & " Mb" & "" & ObjRS("XXXXX").VALUE & " %" & ""
> ObjRS.Movenext
> WEND
> ObjRS.CLOSE
> But i receive the following error:
> ADODB.Recordset error '800a0e78'
> Operation is not allowed when the object is closed.
> Whats wrong? Anyone can help me?
> Thanks in advance.
>
>

Sunday, March 25, 2012

calling report in asp.net app

Hello,
I created a few reports by using RS2000, now I want to call these reports in
my asp.net web application through a selection box. What is the best and
easiest way to handle this.
Thanks,
Jim.if you want a dynamic list (a list constructs from the reports available) so
you can access RS through its webservice and retrieve the list of available
reports
Or if the list is limited , then you can fill manually the selection box
with "static" values.
To open and render the report, if the ASP.NET application is on the same
server as RS, then simply open the report with URL access:
/reportserver?/folder/report name
You can use the sample ASP.net control provided with RS to disply the
report.
"JIM.H." <JIMH@.discussions.microsoft.com> a écrit dans le message de news:
185467F1-14DD-4658-A5EE-A2024FC6290D@.microsoft.com...
> Hello,
> I created a few reports by using RS2000, now I want to call these reports
> in
> my asp.net web application through a selection box. What is the best and
> easiest way to handle this.
> Thanks,
> Jim.
>|||Jim,
Easiest may not always be the best way since it depends on your report
requirements. But in general, you should gravitate whenever possible to URL
addressability. The ReportViewer sample that comes with RS makes this
easier.
If you want to be able to switch between URL and SOAP addressibility you may
find my AwReportViewer control (an enhanced version of ReportViewer useful
(http://www.manning-sandbox.com/thread.jspa?threadID=10392&tstart=45). Enjoy
it!
--
Hope this helps.
---
Teo Lachev, MVP [SQL Server], MCSD, MCT
Author: "Microsoft Reporting Services in Action"
Publisher website: http://www.manning.com/lachev
Buy it from Amazon.com: http://shrinkster.com/eq
Home page and blog: http://www.prologika.com/
---
"JIM.H." <JIMH@.discussions.microsoft.com> wrote in message
news:185467F1-14DD-4658-A5EE-A2024FC6290D@.microsoft.com...
> Hello,
> I created a few reports by using RS2000, now I want to call these reports
in
> my asp.net web application through a selection box. What is the best and
> easiest way to handle this.
> Thanks,
> Jim.
>

Calling report from classic ASP

I don't even _have_ VS 6.0 on a machine anywhere, so I can't muck around
with it, so I'm hoping someone can supply sample code and/or links to
examples or other info that can show how to execute a report from "Classic"
ASP (not .NET). We have some legacy apps that aren't being migrated to .NET
and are being maintained off-shore, but want to get Crystal Reports out of
the picture.
Any help will be appreciated.
Thanks,
--StanOn Mar 30, 9:17 am, "Stan Spotts" <sspo...@.community.nospam> wrote:
> I don't even _have_ VS 6.0 on a machine anywhere, so I can't muck around
> with it, so I'm hoping someone can supply sample code and/or links to
> examples or other info that can show how to execute a report from "Classic"
> ASP (not .NET). We have some legacy apps that aren't being migrated to .NET
> and are being maintained off-shore, but want to get Crystal Reports out of
> the picture.
> Any help will be appreciated.
> Thanks,
> --Stan
One option would be to provide a direct link/hyperlink to the Report
Manager from the Classic ASP application. In my experiences, Reporting
Services is not quite as flexible w/Legacy systems as Crystal Reports
is. In .NET, there are about the same.
Regards,
Enrique Martinez
Sr. Software Consultant|||Hi Stan,
For your classic ASP application, is it an public internet application or
for intranet only? As for SQL Server reporting service, if your classic
ASP application's client user can also directly access the reporting
service server, you can directly use "URL ACCESS" to let your asp page
redirect client user to the report server url so as to view the report.
Here is the BOL reference discussing on this:
#SQL Server 2005 Books Online Using URL Access in a Web Application
http://msdn2.microsoft.com/en-us/library/ms153563.aspx
If the SSRS report server is not able to directly access by client user(of
the classic ASP app), I think you can consider the following approach:
** develop a separate ASP.NET web application(a simple .NET application or
component) which access the reporting service webservice and output a
certain report as image or other binary stream.
** your classic ASP page communicate with that .NET based application to
query the binary content of the report and expose it to the end user.
How do you think? Please feel free to post here if you have any further
concerns.
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications.
Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscriptions/support/default.aspx.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.|||Hi Stan,
Have you got any progress or idea on this issue or does the suggestion in
our reply helps some? If there is anything else we can help, please feel
free to post here.
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.|||Steven - thanks, we actually did resort to using url access. I'm not sure
why the developers went that way rather than figurung out how to call the
web services and having it send back HTML, etc., but it was the quick and
dirty way that worked.
Thanks,
--Stan
"Steven Cheng[MSFT]" <stcheng@.online.microsoft.com> wrote in message
news:otVgSQPdHHA.6068@.TK2MSFTNGHUB02.phx.gbl...
> Hi Stan,
> For your classic ASP application, is it an public internet application or
> for intranet only? As for SQL Server reporting service, if your classic
> ASP application's client user can also directly access the reporting
> service server, you can directly use "URL ACCESS" to let your asp page
> redirect client user to the report server url so as to view the report.
> Here is the BOL reference discussing on this:
> #SQL Server 2005 Books Online Using URL Access in a Web Application
> http://msdn2.microsoft.com/en-us/library/ms153563.aspx
> If the SSRS report server is not able to directly access by client user(of
> the classic ASP app), I think you can consider the following approach:
> ** develop a separate ASP.NET web application(a simple .NET application or
> component) which access the reporting service webservice and output a
> certain report as image or other binary stream.
> ** your classic ASP page communicate with that .NET based application to
> query the binary content of the report and expose it to the end user.
> How do you think? Please feel free to post here if you have any further
> concerns.
> Sincerely,
> Steven Cheng
> Microsoft MSDN Online Support Lead
>
> ==================================================> Get notification to my posts through email? Please refer to
> http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
> ications.
>
> Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
> where an initial response from the community or a Microsoft Support
> Engineer within 1 business day is acceptable. Please note that each follow
> up response may take approximately 2 business days as the support
> professional working with you may need further investigation to reach the
> most efficient resolution. The offering is not appropriate for situations
> that require urgent, real-time or phone-based interactions or complex
> project analysis and dump analysis issues. Issues of this nature are best
> handled working with a dedicated Microsoft Support Engineer by contacting
> Microsoft Customer Support Services (CSS) at
> http://msdn.microsoft.com/subscriptions/support/default.aspx.
> ==================================================>
> This posting is provided "AS IS" with no warranties, and confers no
> rights.
>
>
>
>|||Hi,
I have Same issue , but my Classic ASP Application user is not a valid user
on SRS Server , so a challenge page shows up when I do Response.Redirect ,
how get around this , is there a way I can Impersonate as valid SRS USR
just before Redirect ?
"Stan Spotts" wrote:
> Steven - thanks, we actually did resort to using url access. I'm not sure
> why the developers went that way rather than figurung out how to call the
> web services and having it send back HTML, etc., but it was the quick and
> dirty way that worked.
> Thanks,
> --Stan
> "Steven Cheng[MSFT]" <stcheng@.online.microsoft.com> wrote in message
> news:otVgSQPdHHA.6068@.TK2MSFTNGHUB02.phx.gbl...
> > Hi Stan,
> >
> > For your classic ASP application, is it an public internet application or
> > for intranet only? As for SQL Server reporting service, if your classic
> > ASP application's client user can also directly access the reporting
> > service server, you can directly use "URL ACCESS" to let your asp page
> > redirect client user to the report server url so as to view the report.
> > Here is the BOL reference discussing on this:
> >
> > #SQL Server 2005 Books Online Using URL Access in a Web Application
> > http://msdn2.microsoft.com/en-us/library/ms153563.aspx
> >
> > If the SSRS report server is not able to directly access by client user(of
> > the classic ASP app), I think you can consider the following approach:
> >
> > ** develop a separate ASP.NET web application(a simple .NET application or
> > component) which access the reporting service webservice and output a
> > certain report as image or other binary stream.
> >
> > ** your classic ASP page communicate with that .NET based application to
> > query the binary content of the report and expose it to the end user.
> >
> > How do you think? Please feel free to post here if you have any further
> > concerns.
> >
> > Sincerely,
> >
> > Steven Cheng
> >
> > Microsoft MSDN Online Support Lead
> >
> >
> >
> > ==================================================> >
> > Get notification to my posts through email? Please refer to
> > http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
> > ications.
> >
> >
> >
> > Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
> > where an initial response from the community or a Microsoft Support
> > Engineer within 1 business day is acceptable. Please note that each follow
> > up response may take approximately 2 business days as the support
> > professional working with you may need further investigation to reach the
> > most efficient resolution. The offering is not appropriate for situations
> > that require urgent, real-time or phone-based interactions or complex
> > project analysis and dump analysis issues. Issues of this nature are best
> > handled working with a dedicated Microsoft Support Engineer by contacting
> > Microsoft Customer Support Services (CSS) at
> > http://msdn.microsoft.com/subscriptions/support/default.aspx.
> >
> > ==================================================> >
> >
> >
> > This posting is provided "AS IS" with no warranties, and confers no
> > rights.
> >
> >
> >
> >
> >
> >
> >
> >
>
>sql

Thursday, March 22, 2012

calling rdl from ASP page?

Hi everyone,

I'd like to call a report from an ASP 3.0 page. How could I do such thing?

Thanks for any link or sample provided,

Regards,

Hi,

You need to take a look at the ReportViewer control. It is also possible to use RDLC reports which are the same as normal RDL reports but they are included your project and don't need a reporting server anymore.

References:

Sample project in ASP.NET 2.0: http://www.codeproject.com/aspnet/ReportViewer.asp|||thanks for that.

Tuesday, March 20, 2012

Calling DTS via ASP.NET works locally but not when published to intranet

I have a DTS package that I am calling in my code-behind (vb) of one of my asp.net pages on my intranet. The package takes a FoxPro table that is on our network and inserts it into a SQL Server table in one of our databases. The package gets called and executed properly when I am working on it in development on my local workstation, but when I publish it to our intranet, which is in the same domain and behind the same firewall, the package does not execute. No error shows up on the published page, but also nothing gets executed. Has anyone encountered this? Here is my code, which is pretty straightforward:

oPkg = Server.CreateObject(

"DTS.Package")
oPkg.LoadFromSQLServer("[servername]","sa","[password]", DTSSQLStgFlag_Default,"","","","Invoice Import")
oPkg.Execute()

Any help would be appreciated. Thanks.

The problem is you are using the wrong user to run the DTS package because when Asp.net is running the package it runs under the Agent so the better security model is to clone a valid Admin level Windows and SQL Server account to run the package. I have covered it in the thread below, if you run into problem try again it will work. Hope this helps.

http://forums.asp.net/thread/1522519.aspx

|||

Isn't asp.net running the package when I am going through my browser on localhost? Could you elaborate on how asp.net would use sa effectively when I'm using a browser in VS and it wouldn't when I publish? That doesn't make much sense.

|||

I have explained in detail in the thread I posted earlier it is not SA(system Admin) related you need an account with Network permissions for the SQL Server Agent service which is reponsible for automations in SQL Server. You could be using browser in VS but this is something only SQL Server control and I have wondered why it is barely documented but running DTS in web applications was created by SQL Server users not Microsoft so documentation is not comprehensive. What I know is if you don't give the Agent the right permissions it will not work.

So you need a domain account with Admin level permissions create Admin level SQL Server permissions then use that account to create a proxy account for SQL Server Agent to run your package with xp_cmdshell. You are not the first to ask this question and will not be the last but read that thread do everything correctly and it will work. Hope this helps.

Calling DTS from ASP throught ISA Firewall

I am trying to execute a DTS package from our external web site. The package resides on an SQL Server inside the ISA firewall. I can connect to the SQL Server via ADO but everything else is blocked so the following code will not work since I believe it uses Windows Integrated Security:

Dim oPkg
Dim objCID
Dim objSID
Dim objOrderID

Set oPkg = CreateObject("DTS.Package")

Set objCID = oPkg.GlobalVariables.New("@.CID")
Set objSID = oPkg.GlobalVariables.New("@.SID")
Set objOrderID = oPkg.GlobalVariables.New("@.OrderID")

oPkg.LoadFromSQLServer "ServerName", "UserName", "Password", , , , , "MSIOrder"

objCID.Value = "2303"
objSID.Value = "822105614"
objOrderID.Value = "323"
oPkg.GlobalVariables.Add objCID
oPkg.GlobalVariables.Add objSID
oPkg.GlobalVariables.Add objOrderID

oPkg.Execute
Set oPkg = Nothing

Is there a way to call this DTS package via an ADO connection? And of course, to complicate things, I need to pass the DTS package three global variables.

Lastly, modifying the ISA config is not an option unless I can be absolutely sure that it would not alter our current level of security.

Thanks in advance,
JimDTS? Ick. Anyway, are you sure you have the DTS DLLs installed on the client machine (this case the web server)? I believe you need to install Enterprise Manager on the machine for those DLLs to get installed. No separate installation as far as I know.

Also, what error message are you getting?
~Mattsql

calling another server connection through a stored procedure

anybody have an idea how to call a server through a stored procedure...

ex)
from my asp, i connect to sql server then call a stored procedure...in the stored procedure i want to connect to a remote database (jdedwards) and bring back tables to use in that procedure that eventually is used for output.

how do you make the connection to jde?You can do it through either linked server or remote server. Either way, you need to register the 2nd server on the first server. Provided permision is granted, you then run query in the 'select * from serverName.dbName.owner.tableName' format.|||thanks!

but now HOW DO I register my sql server to connect to a non Sql Server....the only way I can connect to the other Database is through ODBC? In other words, I need my sql server's stored procedure to ODBC to a non SQL server; i.e., AS/400.

Thursday, March 8, 2012

calling a C# assembly from SQL Server 2005

Hi,

I have got a simple C# assembly which call a ASP.net web service and executes a webmethod, now i want to call this assembly from sql server 2005 within the sql server function. can any body let me know how to do it.

Thanks

I suggest you get a copy of "Professional SQL Server 2005 CLR Programming" published by WROX - ISBN 0-470-05403-4. You should be able to read a copy on Safari.

The rules on what may and may not be called are lengthy. It would have to be used with a permission set of EXTERNAL_ACCESS as it access the network. Not all DBA's will allow this.

Have you rigoursly unit tested the application? Do you tests reach at least 80-90% code coverage?

Depending on how exactly you wrote your application, you might have to rewrite some of it. For example the SQL access methods are in a different namespace within the SQL CLR.

Call to Report Mqanager through Internet

Hi All,

Is it possible to call report manager through ASP.NET application?

We are using Microsoft Active Directory to validate users.

If the user type is admin then we would like to call the report manager so that the admin can create roles etc.

Does anyone knows how to do this?

Report Manager uses the report server SOAP API to perform management tasks. You can use this same API for your own applications. See http://msdn2.microsoft.com/en-us/library/ms152787(SQL.90).aspx|||

Thanks for the info. It looks like we can develop our own custom Report Manager using APIs. But we don't have time to do this.

So, is it possible to call report manager from web application? Something like..

http:/ReportSever/Reports and the admin can see just his folder(s).

|||Anyone know about this?|||

You can access Report Manager Folder the same way that you access other Virtual Directories. Go to your IIS Admin and look for Reports Virtual Directory and set up the security that you need. the URL should be somethig like:

http://YourServerOrIPAddress/Reports

|||Thanks much!!

Call to Report Manager through Internet

Hi All,

Is it possible to call report manager through ASP.NET application?

We are using Microsoft Active Directory to validate users.

If the user type is admin then we would like to call the report manager so that the admin can create roles etc.

Does anyone knows how to do this?

Report Manager uses the report server SOAP API to perform management tasks. You can use this same API for your own applications. See http://msdn2.microsoft.com/en-us/library/ms152787(SQL.90).aspx|||

Thanks for the info. It looks like we can develop our own custom Report Manager using APIs. But we don't have time to do this.

So, is it possible to call report manager from web application? Something like..

http:/ReportSever/Reports and the admin can see just his folder(s).

|||Anyone know about this?|||

You can access Report Manager Folder the same way that you access other Virtual Directories. Go to your IIS Admin and look for Reports Virtual Directory and set up the security that you need. the URL should be somethig like:

http://YourServerOrIPAddress/Reports

|||Thanks much!!

Wednesday, March 7, 2012

call SQL job in ASP.NET application

is it possible to call a SQL job from an ASP.NET application? if so, how? I'm using VS.net2003 and am programming in C#

I've been searching for a while, but haven't found anything. It doesn't help that one of my keywords when searching is "job(s)."

Look at the stored procedure sp_start_job in SQL Server Books online.

Call RS from

Hi,
I am creating an asp.net app and was wondering how I can call up a report
created in RS from my app?
Does anyone have any websites or docs on how to use RS?
Thanks,
JJTake a look at the ReportViewer sample code from Microsoft. It should land
in your install folder under Samples\Applications.
Cheers,
--
'(' Jeff A. Stucker
\
Business Intelligence
www.criadvantage.com
---
"JJ" <JJ@.discussions.microsoft.com> wrote in message
news:AC6C1281-C687-41A0-A37D-11E1C2F7F71D@.microsoft.com...
> Hi,
> I am creating an asp.net app and was wondering how I can call up a report
> created in RS from my app?
> Does anyone have any websites or docs on how to use RS?
> Thanks,
> JJ|||You can find more info about RS here:
www.ReportingServicesFaq.com
And there is a RS Wiki community being built here:
www.ReportingServicesFaq.com/ow.asp
Jeff A. Stucker wrote:
> Take a look at the ReportViewer sample code from Microsoft. It should land
> in your install folder under Samples\Applications.
> Cheers,
>|||go thorugh this link a wonderful article on how to: reporting services
http://www.15seconds.com/issue/041013.htm
raj.
"RS Guy" wrote:
> You can find more info about RS here:
> www.ReportingServicesFaq.com
> And there is a RS Wiki community being built here:
> www.ReportingServicesFaq.com/ow.asp
>
> Jeff A. Stucker wrote:
> > Take a look at the ReportViewer sample code from Microsoft. It should land
> > in your install folder under Samples\Applications.
> >
> > Cheers,
> >
>

Call DTS Package from ASP via SP runs it 2x. Runs fine from w/in SQL

I have a DTS package that is called from a SP in SQL Server 2000. When it is run from within SQL, the profiler shows that the Application "DTS Designer" is only called once and does it's tasks and returns the recordset....

When the SP is called from via ASP, the profiler shows that the Application "DTS Designer" actually runs 2x before returning... asside from killing efficiency, the extra run is also causing my page to take forever (15 minutes)

ASP Call:
myDSN=<DSNString> (works fine...)
Set DataConn = Server.CreateObject("ADODB.Connection")
DataConn.Open myDSN
pcuserid = "DBUsername"
pcpassword = "DBPassword"
strQuery = "exec usa_runimportcreditdtspkg @.importfilename= '" & psFileName & "', @.userid= '" & pcuserid & "',@.password='" & pcpassword & "' "
Set rsMain = Server.CreateObject("ADODB.RecordSet")
rsMain.Open strQuery,DataConn,1,3

Here is the SP code:
declare @.hr as int,
@.opkg as int -- the object token that will refer to the created PKG

--Creating the DTS Package Object:
EXEC @.hr = sp_OACreate 'DTS.Package', @.oPKG OUT
IF @.hr <> 0
BEGIN
PRINT '*** Create Package object failed'
EXEC sp_displayoaerrorinfo @.oPKG, @.hr
RETURN
END

--Loading the Package:
declare @.loadstring as varchar(250)
set @.loadstring = 'LoadFromSQLServer("WEBDEV1", "'+rTrim(@.userid)+'", "'+rTrim(@.password)+'", 0, , , , "importcredits")'

EXEC @.hr = sp_OAMethod @.oPKG,@.loadstring, NULL
IF @.hr <> 0
BEGIN
PRINT '*** Load Package failed'
EXEC sp_displayoaerrorinfo @.oPKG, @.hr
RETURN
END

-- clear out the table before proceeding if it exists
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[ImportCredits]')
and OBJECTPROPERTY(id, N'IsUserTable') = 1)
BEGIN
delete from ImportCredits where employeeSSN is not null
END

-- use the passed filename to set the global variable inside the pkg
EXEC @.hr = sp_OASetProperty @.oPKG, 'GlobalVariables("ImportFilename").Value', @.importfilename

--Executing the Package:
EXEC @.hr = sp_OAMethod @.oPKG, 'Execute'
IF @.hr <> 0
BEGIN
PRINT '*** Execute failed'
EXEC sp_displayoaerrorinfo @.oPKG , @.hr
RETURN
END

--Cleaning up:
EXEC @.hr = sp_OADestroy @.oPKG
IF @.hr <> 0
BEGIN
PRINT '*** Destroy Package failed'
EXEC sp_displayoaerrorinfo @.oPKG, @.hr
RETURN
END

select <Fields>
from <DTSPopulatedTable> i
where substring(invoiceno,1,3)<> 'PSI' and amount > 0
order by customer,employeessn,invoicenoHere's a few ideas...I'd try each of these steps in order one at a time until you get the performance you want.

1) It looks like you are using a DSN as your connection when you create the connection object. First, I'd try using the OLE DB for SQL Server instead. I have found that using the OLE DB provider, rather than a DSN or a "DSN-less" connection, is a lot faster. Either way, you want to do this step. By using an OLE DB connection, you won't need a DSN at all for the ASP connection. This has its advantages too.

2) Next, I would explicitly tell the Recordset object that I am executing a stored procedure, rather than passing SQL that states "EXEC spXXXX", by using the adCmdStoredProc constant in the last argument of the Open method. You may see some improvements there too.

3) Last, try using a command object with the recordset object since you are executing stored procedures.

Here is some sample code to get you started...

' try these one at a time, but build them in order. Do step 1 AND step 2, or do step 1 AND step 3
Dim strcon, con, rst, cmd ' need cmd object variable only if you try step 3

' >>> step 1
' create string to use to connect to SQL Server
strcon = "Provider=SQLOLEDB; Data Source=ServerName; Initial Catalog=DBName; User ID=UserName; Password=Password;"

' instantiate connection object
Set con = Server.CreateObject("ADODB.Connection")

' open connection to SQL Server using the connection string
con.Open strcon

' >>> step 2
' instantiate recordset object
Set rst = Server.CreateObject("ADODB.Recordset")

' open the recordset object (execute the stored procedure)
' you need to use the integer constants for the CursorType, LockType, and Options arguments in ASP (sorry, I don't know them off hand)
rst.Open "sp_name", con, CursorType, LockType, adCmdStoredProc

' >>> step 3
' using the command object can be a bit tricky. I never tried it in ASP, just VB 6, so I'm only guessing on my conversions since the syntax is totally different...

' instantiate command object
Set cmd = Server.CreateObject("ADODB.Command")

' set command type and command text
cmd.CommandType = adCmdStoredProc
cmd.CommandText = "sp_name"

' create and set the parameter values (only if there are input parms for the sp) otherwise, you don't need these next two groups of code...
cmd.Parameters.Append("parm1", DataType, adParamInput)
cmd.Parameters.Append("parm2", DataType, adParamInput)
cmd.Parameters("parm1").Value = "value for first parameter"
cmd.Parameters("parm2").Value = "value for second parameter"

' associate the command object with the connection object
cmd.ActiveConnection = con

' open the recordset object (execute the stored procedure)
Set rst = cmd.Execute

Another thing is that you may want to try tweaking the CursorType and LockType arguments whenever you call the Recordset.Open method for either steps 2 or 3 depending on what you want to do with the recordset. Be sure to only use the minimum amount of locking or cursor fetching capabilities you absolutely need to maximize performance.

Lastly...whew! With regards to VBScript and ASP, you may want to use the Response.Buffer and flush it at times depending on how you want to display the page in the browser.

If you have any questions, feel free to ask.

HTH!

Kael

call an ASP page using xp_cmdShell

Hi, here is what I'm trying to accomplish. I'm using Win2k, IIS, SQL Server 2000 sp3a. I'm trying to call an ASP page from the SQL environment. The ASP page updates a record in a database.

Code in Query Analyzer:
exec master..xp_cmdshell 'c:\temp\test.vbs'

If I double-click the vbs file from Windows Explorer, the vbs file calls the asp file and the database updates. When I run the code in SQL I get a message telling me 1 row was affected, yet no record was written to the DB. I've read an article telling me it was possible to call an ASP page from SQL. http://www.eggheadcafe.com/articles/20010426.asp . But it does not work for me?

Code for VBS and ASP files, I don't think the problem is here though?

VBS:
Set WshShell = WScript.CreateObject("WScript.Shell")
URL = "http://localhost/spg/sprocData.asp"
WshShell.Run(URL)
set WshShell = Nothing

ASP:
dim objConn1,objCmd1, strSQL, adCmdText
adCmdText = 1
strSQL = "INSERT INTO tblXMLInsert (SEQ, VENDORID) VALUES ('test','test')"

set objConn1 = Server.CreateObject("ADODB.Connection")
objConn1.Open "Provider=SQLOLEDB;Server=SERVER;Database=SPG;UID=t est;PWD=test"
set objCmd1 = Server.CreateObject("ADODB.Command")
set objCmd1.ActiveConnection = objConn1
objCmd1.CommandText = strSQL
objCmd1.CommandType = adCmdText
objCmd1.Execute
set objConn1 = Nothing
set objCmd1 = Nothing

Thanks for your help.Sorry dude....

I have to say this...Why the heck are you making life hard for yourself?

Web stuff stays on the web server
SQL stuff stays on the SQL Server.

xp_cmdshell is a VERY DANGEROUS utility - it usually operates at sa level and unless you want to trash your SQL server - dont use it. Just dont!

It may be the permissions of the user you are using to access SQL server from the seb server. Make sure the test user has change permissions on the table you are trying to alter. Start SQL Analyser & connect to the database using the test user. If you manually run the TSQL code in SQL Analyser on the server & it works, then its not permissions issue for the user.
It may be your vbs code.

Post back if problems.

Cheers,

SG|||hahahaha... thats right, dont mix...

I never cant do that... If you can... tell me how :)|||Let me explain what I'm trying to accomplish, it sounds like there is a better way to do this. I have an insert/update trigger that will use the xp_cmdshell command. I call the ASP page with 1 variable. The ASP page queries the database for a bunch of records, based on the variable I receive from the trigger. The returned recordset is parsed and converted to XML then sent to an external server. The ASP page receives the status of the file transfer and I update our database accordingly. The code posted above obviously does not show all these steps. Thanks|||Hi

CAN I BE MORE BLUNT???

DONT USE XP_CMDSHELL FOR THIS!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

ASP is designed to interact with a database, and send/retrieve information and I'm guessing you are still learning how to do this. Best method of attack is not to short circuit security ( and any good DBA will tell you this ) by not uising xp_cmdshell ( A good DBA will also "break" your fingers for using xp_cmdshell so be warned ). Not all you read on development boards is correct nor security minded.

Get all your development in ASP correct from the ground up & with solid engineering approach. You will be better off in the long run AND if someone managed to exploit this xp_cmdshell link, they could easily compromise your site security - ( www.sqlsecurity.com ) .

Fancy a pink slip for this effort? It would be worth doing to get rid of someone who KNOWINGLY compromised my site security.

SQL 2000 will return records in XML natively so you can do everything within TSQL and pass the trigger result back to an ASP page easily enough. Work it out correctly - dont make nasty short cuts.

HTH

Cheers,

SG.|||Hi, sqlguy7777. Your last statement says:
SQL 2000 will return records in XML natively so you can do everything within TSQL and pass the trigger result back to an ASP page easily enough. Work it out correctly - dont make nasty short cuts.

Creating XML in TSQL is no problem, my problem is passing the trigger results back to the ASP page. How do I do that, if xp_cmdShell is not the way to go what is the better way. Thanks|||Howdy,

I think you may have to change the approach to the problem & how you are handling the changes to the data & the database.

I was thinking through the problem, and it occurs to me you are making life difficult for yourself.

Instead of messing around with vbs scripts & triggers shooting info backwards & forwards, keep all the database functionality within the database. You could write a trigger result to a table, then scan the table frequently via a script to look for a change and then kick an action off. If you are only scanning a small table it would take milliseconds for a scan so unless your server is being flogged into the ground, speed should not be an issue. ( assuming you are not doing this 1000s of times a second, in which case using a RAM based pinned table would be much quicker. )

Keep it simple & it stays robust/reliable. As soon as it gets messy, the chance of things going wrong goes throught he roof. I speak from hard learned experience. Of course, you can totally dismiss what I'm saying ( which is you choice of course ) but I am trying to save you some grief.

I'd also suggest you talk to your DBA - quite often they can help with design issues and it makes long term support of systems easier & cheaper & faster.

HTH,

Cheers,

SG.

Saturday, February 25, 2012

Calendar picker?

Hi there
I am trying to set up some sort of date picker for my reports in Reporting
Services and found an article which basically uses an asp.net calendar
control as a plug-in to the report (see link below).
http://groups-beta.google.com/group/microsoft.public.sqlserver.reportingsvcs/browse_thread/thread/6e8cee511769b6c/1ddce2c2c6523fc0?q=&_done=/groups?enc_author=uFKGehIAAAAdZvNtw6tRAoeBJxgAOEvh8rhlH0Pnl47z4AZhN98BFg&&_doneTitle=Back%20to%20Search&d=&
Unfortunately I am not very experienced in programming, so i don't fully
understand how you would integrate the asp page with the report.
My reports are based on an Analysis Services cube time dimension. i have an
MDX statement in the Data query window in .NET which populates a Matrix
table. The query looks like this:
SELECT { Measures.members } on Columns ,
NON EMPTY {{[Business].[User].[Business Entity Id].[891].Children}
* {[Time].[2004].[Quarter 1].[1].[January]:[Time].[2005].[Quarter
1].[1].[January]}} on Rows
FROM UsageStats_Phase1
I then deploy the report to the Reporting Server manually. How would I
integrate an asp calendar control into this set up? Any help would be most
appreciated!!!
Thanks and regardsRight now, there's not a good way to customize the parameter input process
other than programming. The hyperlink you posted is a very good starting
point.
--
Cheers,
'(' Jeff A. Stucker
\
Business Intelligence
www.criadvantage.com
---
"Neile" <Neile@.discussions.microsoft.com> wrote in message
news:BE9EB249-A29F-47A2-9D17-18632D47A1E6@.microsoft.com...
> Hi there
> I am trying to set up some sort of date picker for my reports in Reporting
> Services and found an article which basically uses an asp.net calendar
> control as a plug-in to the report (see link below).
> http://groups-beta.google.com/group/microsoft.public.sqlserver.reportingsvcs/browse_thread/thread/6e8cee511769b6c/1ddce2c2c6523fc0?q=&_done=/groups?enc_author=uFKGehIAAAAdZvNtw6tRAoeBJxgAOEvh8rhlH0Pnl47z4AZhN98BFg&&_doneTitle=Back%20to%20Search&d=&
> Unfortunately I am not very experienced in programming, so i don't fully
> understand how you would integrate the asp page with the report.
> My reports are based on an Analysis Services cube time dimension. i have
> an
> MDX statement in the Data query window in .NET which populates a Matrix
> table. The query looks like this:
> SELECT { Measures.members } on Columns ,
> NON EMPTY {{[Business].[User].[Business Entity Id].[891].Children}
> * {[Time].[2004].[Quarter 1].[1].[January]:[Time].[2005].[Quarter
> 1].[1].[January]}} on Rows
> FROM UsageStats_Phase1
> I then deploy the report to the Reporting Server manually. How would I
> integrate an asp calendar control into this set up? Any help would be most
> appreciated!!!
> Thanks and regards
>