Hi,
is it possible to start a Report via Link (from Desktop) with start
parameter like an
ASP-Script
For example:
...report.rdl?Year=2007&Month=6...
Thank you
HansThat's what URL access in RS is for.
Amarnath
"Hans" wrote:
> Hi,
> is it possible to start a Report via Link (from Desktop) with start
> parameter like an
> ASP-Script
> For example:
>
> ...report.rdl?Year=2007&Month=6...
>
> Thank you
> Hans
>|||That what I mean ist to start the report from Desktop inclusive
parameters.
Hans|||ok,
so this is a sample you can use to see how it works if you have implemented
the samples and hosted the reports on localserver. copy this url from
desktop.. also you can write asp.net to mask this url and give just a
hyperlink from the page.. see the parameters also passed.
http://server/reportserver?/Sales/Northwest/Employee Sales
Report&rs:Command=Render&EmployeeID=1234
Amarnath
"Hans" wrote:
> That what I mean ist to start the report from Desktop inclusive
> parameters.
> Hans
>|||I tried this, but it doesn=B4t work. The report opens, but there=B4s not
selected parameter value.
Thanks,
Hans|||Hans,
Have you pasted my sample link as a whole URL because it is wraped in the
post.
Incase you have done this pl ignore, you said there is no parameter value,
so I thought you have not pasted the whole URL.
Amarnath, MCTS
"Hans" wrote:
> I tried this, but it doesn´t work. The report opens, but there´s not
> selected parameter value.
>
> Thanks,
> Hans
>
Showing posts with label parameter. Show all posts
Showing posts with label parameter. Show all posts
Friday, March 30, 2012
Link with parameters
Labels:
asp-script,
database,
desktop,
example,
link,
microsoft,
mysql,
oracle,
parameter,
parameters,
rdlyear2007month6,
report,
server,
sql,
via
Monday, March 19, 2012
Line Break down
I have a forumla {@.frmPrevMonth} and it contains information like... "21,36.02,11141.75,1" which it came from a Parameter field.
It can contain more of less information.
What I need is that it can be broke down in order in which they came.
1st Detail line: 21
2nd Detail line: 36.02
3rd Detail line: 11141.75
4th Detail line: 1
How can I achive this?You are going to use the left(), Mid(), and right() functions.
You will have 4 formulas.
This will work for the number you show.
1. Left({@.frmPrevMonth} ,2) // gets 21
2. Mid({@.frmPrevMonth} ,4,5) // gets 36.02
3. Mid({@.frmPrevMonth} 10,8) // gets 11141.75
4. Right({@.frmPrevMonth} ,1) // gets 1
GJ|||I forgot to put down that the numbers vary in size and it is not always 4 things I need. It can be a total of 10 lines or 1 line.|||Ok here is a formula that will get the first strings before the first comma.
I assume you want the values between the commas.
'This formula uses Basic syntax
dim StringInput as string
dim Character as string
dim NumberOfCharacters as number
'The StringInput, Character and NumberOfCharacters
'variables can be changed to your values
StringInput = {@.Number}
Character = ","
NumberOfCharacters = 0
'NumberOfCharacters specifies that the token returned
'If the token to be retrieved comes before the first
'occurrence of Character, use 0 for NumberOfCharacters.
dim Token as number
dim Increment as number
dim Output as string
dim Ender as number
Ender = NumberOfCharacters + 1
do until Token = Ender or Increment = length(StringInput)
Increment = Increment + 1
if StringInput(Increment) = Character then Token= Token + 1
if Ender - Token = 1 and StringInput(Increment) <> Character then Output = Output + StringInput(Increment)
loop
Formula = Output
If you could have up to 10 lines then you will have 10 formulas the way I show, just change the variable at NumberOfCharacters. 1st formula has a 0, 2nd would have a 1 and up to 9 for 10 lines.
Hope that makes sense, someone else might have an easier way of doing this.
GJ|||Look at the help for the Split function, and on arrays.
e.g.
stringvar array parts := split({table.field}); //or maybe numbervar, if all your parts are numbers
parts[2] //return the 2nd part|||Oops, meant to add the 2nd parameter to the split function:
split({table.field}, ',');|||I tried the split function.
Attached is what I am looking for. Thanks.|||Ok here is a formula that will get the first strings before the first comma.
I assume you want the values between the commas.
'This formula uses Basic syntax
dim StringInput as string
dim Character as string
dim NumberOfCharacters as number
'The StringInput, Character and NumberOfCharacters
'variables can be changed to your values
StringInput = {@.Number}
Character = ","
NumberOfCharacters = 0
'NumberOfCharacters specifies that the token returned
'If the token to be retrieved comes before the first
'occurrence of Character, use 0 for NumberOfCharacters.
dim Token as number
dim Increment as number
dim Output as string
dim Ender as number
Ender = NumberOfCharacters + 1
do until Token = Ender or Increment = length(StringInput)
Increment = Increment + 1
if StringInput(Increment) = Character then Token= Token + 1
if Ender - Token = 1 and StringInput(Increment) <> Character then Output = Output + StringInput(Increment)
loop
Formula = Output
If you could have up to 10 lines then you will have 10 formulas the way I show, just change the variable at NumberOfCharacters. 1st formula has a 0, 2nd would have a 1 and up to 9 for 10 lines.
Hope that makes sense, someone else might have an easier way of doing this.
GJ
ok. how can I dynamically increase the "NumberOfCharacters" after everytime a record is read and then have it display it on the detail line?|||Have not had time today to work formula. Why not use the split function like JaganEllis suggested. It's quicker and easier to understand.
GJ|||An example to produce what I think you want:
local stringvar a := "21,36.02,11141.75,1";
local stringvar array parts := split(a, ',');
local numbervar i;
local stringvar out;
for i := 1 to ubound(parts) do
(
out := out + parts[i] + chr(13) + chr(10);
);
out
And remember to check the 'Can Grow' option for the field, in the Common tab of the Format Field option.
It can contain more of less information.
What I need is that it can be broke down in order in which they came.
1st Detail line: 21
2nd Detail line: 36.02
3rd Detail line: 11141.75
4th Detail line: 1
How can I achive this?You are going to use the left(), Mid(), and right() functions.
You will have 4 formulas.
This will work for the number you show.
1. Left({@.frmPrevMonth} ,2) // gets 21
2. Mid({@.frmPrevMonth} ,4,5) // gets 36.02
3. Mid({@.frmPrevMonth} 10,8) // gets 11141.75
4. Right({@.frmPrevMonth} ,1) // gets 1
GJ|||I forgot to put down that the numbers vary in size and it is not always 4 things I need. It can be a total of 10 lines or 1 line.|||Ok here is a formula that will get the first strings before the first comma.
I assume you want the values between the commas.
'This formula uses Basic syntax
dim StringInput as string
dim Character as string
dim NumberOfCharacters as number
'The StringInput, Character and NumberOfCharacters
'variables can be changed to your values
StringInput = {@.Number}
Character = ","
NumberOfCharacters = 0
'NumberOfCharacters specifies that the token returned
'If the token to be retrieved comes before the first
'occurrence of Character, use 0 for NumberOfCharacters.
dim Token as number
dim Increment as number
dim Output as string
dim Ender as number
Ender = NumberOfCharacters + 1
do until Token = Ender or Increment = length(StringInput)
Increment = Increment + 1
if StringInput(Increment) = Character then Token= Token + 1
if Ender - Token = 1 and StringInput(Increment) <> Character then Output = Output + StringInput(Increment)
loop
Formula = Output
If you could have up to 10 lines then you will have 10 formulas the way I show, just change the variable at NumberOfCharacters. 1st formula has a 0, 2nd would have a 1 and up to 9 for 10 lines.
Hope that makes sense, someone else might have an easier way of doing this.
GJ|||Look at the help for the Split function, and on arrays.
e.g.
stringvar array parts := split({table.field}); //or maybe numbervar, if all your parts are numbers
parts[2] //return the 2nd part|||Oops, meant to add the 2nd parameter to the split function:
split({table.field}, ',');|||I tried the split function.
Attached is what I am looking for. Thanks.|||Ok here is a formula that will get the first strings before the first comma.
I assume you want the values between the commas.
'This formula uses Basic syntax
dim StringInput as string
dim Character as string
dim NumberOfCharacters as number
'The StringInput, Character and NumberOfCharacters
'variables can be changed to your values
StringInput = {@.Number}
Character = ","
NumberOfCharacters = 0
'NumberOfCharacters specifies that the token returned
'If the token to be retrieved comes before the first
'occurrence of Character, use 0 for NumberOfCharacters.
dim Token as number
dim Increment as number
dim Output as string
dim Ender as number
Ender = NumberOfCharacters + 1
do until Token = Ender or Increment = length(StringInput)
Increment = Increment + 1
if StringInput(Increment) = Character then Token= Token + 1
if Ender - Token = 1 and StringInput(Increment) <> Character then Output = Output + StringInput(Increment)
loop
Formula = Output
If you could have up to 10 lines then you will have 10 formulas the way I show, just change the variable at NumberOfCharacters. 1st formula has a 0, 2nd would have a 1 and up to 9 for 10 lines.
Hope that makes sense, someone else might have an easier way of doing this.
GJ
ok. how can I dynamically increase the "NumberOfCharacters" after everytime a record is read and then have it display it on the detail line?|||Have not had time today to work formula. Why not use the split function like JaganEllis suggested. It's quicker and easier to understand.
GJ|||An example to produce what I think you want:
local stringvar a := "21,36.02,11141.75,1";
local stringvar array parts := split(a, ',');
local numbervar i;
local stringvar out;
for i := 1 to ubound(parts) do
(
out := out + parts[i] + chr(13) + chr(10);
);
out
And remember to check the 'Can Grow' option for the field, in the Common tab of the Format Field option.
Monday, February 20, 2012
Limit rows in detail section
I'd like to limit the number of rows in my detail section based on a
parameter.
For example, if I might have region and state as groups, and for each
store
I wanted to show the top 5 products (obviously different products in
each store)
by number sold.
But it could be 10 instead of 5 depending on what the user requested.
Any quick thoughts about this?
TIA,
JimMy first choice would be to limit the sql using a dynamic query ie
="select top " & Parameters!NumRows.Value & " * from mytable"
Of course the sql would have to be much fancier to get the top N for each
group..
The other thing you could do is filter in the group..
something about runningcount for the Group < Parameters!NumRows.value
should do it..
--
Wayne Snyder MCDBA, SQL Server MVP
Mariner, Charlotte, NC
I support the Professional Association for SQL Server ( PASS) and it''s
community of SQL Professionals.
"jhcorey@.yahoo.com" wrote:
> I'd like to limit the number of rows in my detail section based on a
> parameter.
> For example, if I might have region and state as groups, and for each
> store
> I wanted to show the top 5 products (obviously different products in
> each store)
> by number sold.
> But it could be 10 instead of 5 depending on what the user requested.
> Any quick thoughts about this?
> TIA,
> Jim
>
parameter.
For example, if I might have region and state as groups, and for each
store
I wanted to show the top 5 products (obviously different products in
each store)
by number sold.
But it could be 10 instead of 5 depending on what the user requested.
Any quick thoughts about this?
TIA,
JimMy first choice would be to limit the sql using a dynamic query ie
="select top " & Parameters!NumRows.Value & " * from mytable"
Of course the sql would have to be much fancier to get the top N for each
group..
The other thing you could do is filter in the group..
something about runningcount for the Group < Parameters!NumRows.value
should do it..
--
Wayne Snyder MCDBA, SQL Server MVP
Mariner, Charlotte, NC
I support the Professional Association for SQL Server ( PASS) and it''s
community of SQL Professionals.
"jhcorey@.yahoo.com" wrote:
> I'd like to limit the number of rows in my detail section based on a
> parameter.
> For example, if I might have region and state as groups, and for each
> store
> I wanted to show the top 5 products (obviously different products in
> each store)
> by number sold.
> But it could be 10 instead of 5 depending on what the user requested.
> Any quick thoughts about this?
> TIA,
> Jim
>
Limit on size of text parameter type in stored procedures?
Hi,
I use stored procedures in combination with openxml. XML text is sent to the
stored procedures as a "text" type parameter.
Is there a limit on the size that this can be? I intend to pass very large
XML documents so its important for us that there is no size limit.
Thanks!
The size limit of text and ntext parameters is 2GB. If you show me an XML
document of that size, I will show you with high probability a design
mistake :-).
Best regards
Michael
"Xerox" <anon@.anon.com> wrote in message
news:eJAPNtVJFHA.2604@.TK2MSFTNGP15.phx.gbl...
> Hi,
> I use stored procedures in combination with openxml. XML text is sent to
> the
> stored procedures as a "text" type parameter.
> Is there a limit on the size that this can be? I intend to pass very large
> XML documents so its important for us that there is no size limit.
> Thanks!
>
|||That's ample! Our files range from 20mb to 100mb. We are planning to make
extensive use of stored procedures and OPENXML - so I just wanted to check
SQL Server would cope with our requirements.
Thanks a lot for the info!!!!
"Michael Rys [MSFT]" <mrys@.online.microsoft.com> wrote in message
news:eVeZJ2fJFHA.656@.TK2MSFTNGP14.phx.gbl...[vbcol=seagreen]
> The size limit of text and ntext parameters is 2GB. If you show me an XML
> document of that size, I will show you with high probability a design
> mistake :-).
> Best regards
> Michael
> "Xerox" <anon@.anon.com> wrote in message
> news:eJAPNtVJFHA.2604@.TK2MSFTNGP15.phx.gbl...
large
>
|||Note that if you are using 20mb to 100mb documents with OpenXML, that you
will have to make sure that your SQL Server instance will have at least x mb
(size of doc) * 4 (avg overhead of DOM) * 8 (1/8th usage limit for OpenXML
in SQL Server) memory available to get acceptable performance. For such
large documents in SQL Server 2000, we normally recommend to use the SQLXML
Bulkload object instead of OpenXML.
Best regards
Michael
"Xerox" <anon@.anon.com> wrote in message
news:e4Ln1CJKFHA.2524@.TK2MSFTNGP10.phx.gbl...
> That's ample! Our files range from 20mb to 100mb. We are planning to make
> extensive use of stored procedures and OPENXML - so I just wanted to check
> SQL Server would cope with our requirements.
> Thanks a lot for the info!!!!
> "Michael Rys [MSFT]" <mrys@.online.microsoft.com> wrote in message
> news:eVeZJ2fJFHA.656@.TK2MSFTNGP14.phx.gbl...
> large
>
I use stored procedures in combination with openxml. XML text is sent to the
stored procedures as a "text" type parameter.
Is there a limit on the size that this can be? I intend to pass very large
XML documents so its important for us that there is no size limit.
Thanks!
The size limit of text and ntext parameters is 2GB. If you show me an XML
document of that size, I will show you with high probability a design
mistake :-).
Best regards
Michael
"Xerox" <anon@.anon.com> wrote in message
news:eJAPNtVJFHA.2604@.TK2MSFTNGP15.phx.gbl...
> Hi,
> I use stored procedures in combination with openxml. XML text is sent to
> the
> stored procedures as a "text" type parameter.
> Is there a limit on the size that this can be? I intend to pass very large
> XML documents so its important for us that there is no size limit.
> Thanks!
>
|||That's ample! Our files range from 20mb to 100mb. We are planning to make
extensive use of stored procedures and OPENXML - so I just wanted to check
SQL Server would cope with our requirements.
Thanks a lot for the info!!!!
"Michael Rys [MSFT]" <mrys@.online.microsoft.com> wrote in message
news:eVeZJ2fJFHA.656@.TK2MSFTNGP14.phx.gbl...[vbcol=seagreen]
> The size limit of text and ntext parameters is 2GB. If you show me an XML
> document of that size, I will show you with high probability a design
> mistake :-).
> Best regards
> Michael
> "Xerox" <anon@.anon.com> wrote in message
> news:eJAPNtVJFHA.2604@.TK2MSFTNGP15.phx.gbl...
large
>
|||Note that if you are using 20mb to 100mb documents with OpenXML, that you
will have to make sure that your SQL Server instance will have at least x mb
(size of doc) * 4 (avg overhead of DOM) * 8 (1/8th usage limit for OpenXML
in SQL Server) memory available to get acceptable performance. For such
large documents in SQL Server 2000, we normally recommend to use the SQLXML
Bulkload object instead of OpenXML.
Best regards
Michael
"Xerox" <anon@.anon.com> wrote in message
news:e4Ln1CJKFHA.2524@.TK2MSFTNGP10.phx.gbl...
> That's ample! Our files range from 20mb to 100mb. We are planning to make
> extensive use of stored procedures and OPENXML - so I just wanted to check
> SQL Server would cope with our requirements.
> Thanks a lot for the info!!!!
> "Michael Rys [MSFT]" <mrys@.online.microsoft.com> wrote in message
> news:eVeZJ2fJFHA.656@.TK2MSFTNGP14.phx.gbl...
> large
>
Limit on size of text parameter type in stored procedures?
Hi,
I use stored procedures in combination with openxml. XML text is sent to the
stored procedures as a "text" type parameter.
Is there a limit on the size that this can be? I intend to pass very large
XML documents so its important for us that there is no size limit.
Thanks!The size limit of text and ntext parameters is 2GB. If you show me an XML
document of that size, I will show you with high probability a design
mistake :-).
Best regards
Michael
"Xerox" <anon@.anon.com> wrote in message
news:eJAPNtVJFHA.2604@.TK2MSFTNGP15.phx.gbl...
> Hi,
> I use stored procedures in combination with openxml. XML text is sent to
> the
> stored procedures as a "text" type parameter.
> Is there a limit on the size that this can be? I intend to pass very large
> XML documents so its important for us that there is no size limit.
> Thanks!
>|||That's ample! Our files range from 20mb to 100mb. We are planning to make
extensive use of stored procedures and OPENXML - so I just wanted to check
SQL Server would cope with our requirements.
Thanks a lot for the info!!!!
"Michael Rys [MSFT]" <mrys@.online.microsoft.com> wrote in message
news:eVeZJ2fJFHA.656@.TK2MSFTNGP14.phx.gbl...
> The size limit of text and ntext parameters is 2GB. If you show me an XML
> document of that size, I will show you with high probability a design
> mistake :-).
> Best regards
> Michael
> "Xerox" <anon@.anon.com> wrote in message
> news:eJAPNtVJFHA.2604@.TK2MSFTNGP15.phx.gbl...
large
>|||Note that if you are using 20mb to 100mb documents with OpenXML, that you
will have to make sure that your SQL Server instance will have at least x mb
(size of doc) * 4 (avg overhead of DOM) * 8 (1/8th usage limit for OpenXML
in SQL Server) memory available to get acceptable performance. For such
large documents in SQL Server 2000, we normally recommend to use the SQLXML
Bulkload object instead of OpenXML.
Best regards
Michael
"Xerox" <anon@.anon.com> wrote in message
news:e4Ln1CJKFHA.2524@.TK2MSFTNGP10.phx.gbl...
> That's ample! Our files range from 20mb to 100mb. We are planning to make
> extensive use of stored procedures and OPENXML - so I just wanted to check
> SQL Server would cope with our requirements.
> Thanks a lot for the info!!!!
> "Michael Rys [MSFT]" <mrys@.online.microsoft.com> wrote in message
> news:eVeZJ2fJFHA.656@.TK2MSFTNGP14.phx.gbl...
> large
>
I use stored procedures in combination with openxml. XML text is sent to the
stored procedures as a "text" type parameter.
Is there a limit on the size that this can be? I intend to pass very large
XML documents so its important for us that there is no size limit.
Thanks!The size limit of text and ntext parameters is 2GB. If you show me an XML
document of that size, I will show you with high probability a design
mistake :-).
Best regards
Michael
"Xerox" <anon@.anon.com> wrote in message
news:eJAPNtVJFHA.2604@.TK2MSFTNGP15.phx.gbl...
> Hi,
> I use stored procedures in combination with openxml. XML text is sent to
> the
> stored procedures as a "text" type parameter.
> Is there a limit on the size that this can be? I intend to pass very large
> XML documents so its important for us that there is no size limit.
> Thanks!
>|||That's ample! Our files range from 20mb to 100mb. We are planning to make
extensive use of stored procedures and OPENXML - so I just wanted to check
SQL Server would cope with our requirements.
Thanks a lot for the info!!!!
"Michael Rys [MSFT]" <mrys@.online.microsoft.com> wrote in message
news:eVeZJ2fJFHA.656@.TK2MSFTNGP14.phx.gbl...
> The size limit of text and ntext parameters is 2GB. If you show me an XML
> document of that size, I will show you with high probability a design
> mistake :-).
> Best regards
> Michael
> "Xerox" <anon@.anon.com> wrote in message
> news:eJAPNtVJFHA.2604@.TK2MSFTNGP15.phx.gbl...
large
>|||Note that if you are using 20mb to 100mb documents with OpenXML, that you
will have to make sure that your SQL Server instance will have at least x mb
(size of doc) * 4 (avg overhead of DOM) * 8 (1/8th usage limit for OpenXML
in SQL Server) memory available to get acceptable performance. For such
large documents in SQL Server 2000, we normally recommend to use the SQLXML
Bulkload object instead of OpenXML.
Best regards
Michael
"Xerox" <anon@.anon.com> wrote in message
news:e4Ln1CJKFHA.2524@.TK2MSFTNGP10.phx.gbl...
> That's ample! Our files range from 20mb to 100mb. We are planning to make
> extensive use of stored procedures and OPENXML - so I just wanted to check
> SQL Server would cope with our requirements.
> Thanks a lot for the info!!!!
> "Michael Rys [MSFT]" <mrys@.online.microsoft.com> wrote in message
> news:eVeZJ2fJFHA.656@.TK2MSFTNGP14.phx.gbl...
> large
>
Subscribe to:
Posts (Atom)