Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Shaun E on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Parameter Problems

Status
Not open for further replies.

slr22

MIS
Jun 26, 2002
80
US
I'm trying to get a report to show up on the web. I am using visual interdev for my web page design. I'm using an asp page with session variables. I've done this before, but now I can't get this report to work. I have one parameter, it is based on a quote number. The report works fine in Crystal when I refresh the report it asks for the parameter and gives me only that parameter, however when I try to get it to work on the web it doesn't give what is selected on the web. One report it gives me everything one report it give me nothing. I've looked at my old code for the web page and everything looks the same. I've done the report two different ways to see if there is something messed up with the report.

Here is my sql for my one report using a stored procedure:

{call company.dbo.test_quote;1(?)}

when I do this only it give me everything...When I go to Report --> Edit Selection Formula --> Record

When I put in this formula:

{test_quote;1.quote_number}={?@QuoteNum}

it give me nothing only the report headers/titles.

In the visual interdev I put the following code:

<%
reportname = &quot;Report3.rpt&quot;
%>
%>
<!-- #include file=&quot;AlwaysRequiredSteps.asp&quot; -->
><%

Session(&quot;oRpt&quot;).ParameterFields.GetItemByName(&quot;@QuoteNum&quot;).AddCurrentValue(Session(&quot;QuoteNum&quot;))


%>
<!-- #include file=&quot;MoreRequiredSteps.asp&quot; -->

<%
%>
<!-- #include file=&quot;SmartVieweractivex.asp&quot; -->

Does anyone any suggestions on why this isn't working. Any help would be greatly appreciated.

Thanks in advance.

Sandy


 
{test_quote;1.quote_number}={?@QuoteNum}

****************

{?@QuoteNum} This is a weird parameter name....is @QuoteNum a formula????...I don't know much about the rest of your problem but this bothered me.



Jim Broadbent
 
@QuoteNum is my parameter name.....I changed it to

{test_quote;1.quote_number}={?Quote}

changing my parameter name to Quote and it makes no difference.
 
I didn't think it would if it was just the name....just confusing is all...

Again...pardon me for being anal about syntax but is the &quot;;&quot; necessary in this

{call company.dbo.test_quote;1(?)}

why not just

{call company.dbo.test_quote1(?)}

****************

also

{test_quote;1.quote_number} ={?@QuoteNum}

does not &quot;Assign&quot; the parameter to {test_quote;1.quote_number} ....perhaps you should use &quot;:=&quot; instead as &quot;=&quot;

I don't know if this helps but all I can offer

Jim Broadbent
 
The ; goes in there automatically when you double click the field to put it in the formula. It puts it in there because it is a stored procedure. I've also tried the report without the stored procedure and just the tables and it gives me the same results for the report.

If I do the := in the formulat it give me an error.

Thanks,
Sandy
 
ok....i don't work with stored procedures .... SynapseVampire should be able to help you though

Jim Broadbent
 
Ok, I figured it out. It was datatype issue.

Thanks,
Sandy
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top