Showing posts with label parent. Show all posts
Showing posts with label parent. Show all posts

Wednesday, March 28, 2012

Passing multivalued parameter from parent report to child report in Reporting service

I have report which accepts multi Value paramter in the Parent Report, this report has a drill down feature. but when i try passing the multi value parameter to the child report only the 1st value in the list is passed.

Parent Report accepts multiple users and based on which it shows the total % of issues submitted by thoses selected users in the multi value list. on drill down i need to send the user list again from the parent so that the child report shows each issue in detail. but when i use Parameters!Users.value i get only the 1st selected value.

could any one pls help me achive this requirement of mine.

thanks

Chandresh Soni

Are the data coming from Analysis Services or are they based on a relational data source?

For the relational case I recommend reading the following forum posting: http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=163803&SiteID=1

-- Robert

|||

Yes the data in the first report was coming through relational database. and i had given a drill down feature in the first report which takes to the second report which shows the details information off the parameter(multivalued) selected from the first. it worked for me.

I appreciate yr help - Robert

passing multi-value parameter to subreport

ok - i've googled this and have tried everything to no avail...
parent report has multi-value parameter: part_code
this gets passed to subreport which has part_code setup as multi-
valued paramter
what is the syntax in the parent...subreport properties/parameters box
and
what is the syntax in the child report parameters form?
thanks very muchon the subreport properties->parameters give
"=Join(Parameters! <ParameterName> .Value,", ") so that the multi value is
passed to the subreport as well.
Amarnath, MCTS
"roy@.mgk.com" wrote:
> ok - i've googled this and have tried everything to no avail...
> parent report has multi-value parameter: part_code
> this gets passed to subreport which has part_code setup as multi-
> valued paramter
> what is the syntax in the parent...subreport properties/parameters box
> and
> what is the syntax in the child report parameters form?
>
> thanks very much
>|||On Mar 21, 9:10 am, Amarnath <Amarn...@.discussions.microsoft.com>
wrote:
> on the subreport properties->parameters give
> "=Join(Parameters! <ParameterName> .Value,", ") so that the multi value is
> passed to the subreport as well.
> Amarnath, MCTS
>
> "r...@.mgk.com" wrote:
> > ok - i've googled this and have tried everything to no avail...
> > parent report has multi-value parameter: part_code
> > this gets passed to subreport which has part_code setup as multi-
> > valued paramter
> > what is the syntax in the parent...subreport properties/parameters box
> > and
> > what is the syntax in the child report parameters form?
> > thanks very much- Hide quoted text -
> - Show quoted text -
did that Amarnath ))...and i have in the parent the subreport
properties/parameters: "=Parameters!PART_CODE"
all i get is 'error - subreport could not be shown'......|||On Mar 22, 8:07 am, r...@.mgk.com wrote:
> On Mar 21, 9:10 am, Amarnath <Amarn...@.discussions.microsoft.com>
> wrote:
>
>
> > on the subreport properties->parameters give
> > "=Join(Parameters! <ParameterName> .Value,", ") so that the multi value is
> > passed to the subreport as well.
> > Amarnath, MCTS
> > "r...@.mgk.com" wrote:
> > > ok - i've googled this and have tried everything to no avail...
> > > parent report has multi-value parameter: part_code
> > > this gets passed to subreport which has part_code setup as multi-
> > > valued paramter
> > > what is the syntax in the parent...subreport properties/parameters box
> > > and
> > > what is the syntax in the child report parameters form?
> > > thanks very much- Hide quoted text -
> > - Show quoted text -
> did that Amarnath ))...and i have in the parent the subreport
> properties/parameters: "=Parameters!PART_CODE"
> all i get is 'error - subreport could not be shown'......- Hide quoted text -
> - Show quoted text -
i should've said i implemented that...as well as the "=Parameters!
PART_CODE" in my previous reply...
is there some change in the SQL?...i'm just using the "....part_code
in (@.PART_CODE)" with the paramter setup normailly in the subreport's
report parameter properties......|||To be very clear, The problem is due to parameters only. First go to the
report which you include as "Subreport" in the main report. open the report
properties, check for multi-value.
close that remaining same. (ie string, non queried or queried, default null.)
Go to the main report where you have placed subreport. on the subreport
right click for properties and the parameter, this is the main culprit for
not working.
Parameter Name: select from the drop down.
Parameter Value: "=Parameters!cn.Value" here just include value instead of
Value(0)
This should work. Let me know if it works.
Amarnath, MCTS.
"roy@.mgk.com" wrote:
> On Mar 22, 8:07 am, r...@.mgk.com wrote:
> > On Mar 21, 9:10 am, Amarnath <Amarn...@.discussions.microsoft.com>
> > wrote:
> >
> >
> >
> >
> >
> > > on the subreport properties->parameters give
> > > "=Join(Parameters! <ParameterName> .Value,", ") so that the multi value is
> > > passed to the subreport as well.
> >
> > > Amarnath, MCTS
> >
> > > "r...@.mgk.com" wrote:
> > > > ok - i've googled this and have tried everything to no avail...
> >
> > > > parent report has multi-value parameter: part_code
> >
> > > > this gets passed to subreport which has part_code setup as multi-
> > > > valued paramter
> >
> > > > what is the syntax in the parent...subreport properties/parameters box
> >
> > > > and
> >
> > > > what is the syntax in the child report parameters form?
> >
> > > > thanks very much- Hide quoted text -
> >
> > > - Show quoted text -
> >
> > did that Amarnath ))...and i have in the parent the subreport
> > properties/parameters: "=Parameters!PART_CODE"
> >
> > all i get is 'error - subreport could not be shown'......- Hide quoted text -
> >
> > - Show quoted text -
> i should've said i implemented that...as well as the "=Parameters!
> PART_CODE" in my previous reply...
> is there some change in the SQL?...i'm just using the "....part_code
> in (@.PART_CODE)" with the paramter setup normailly in the subreport's
> report parameter properties......
>|||On Mar 23, 1:21 am, Amarnath <Amarn...@.discussions.microsoft.com>
wrote:
> To be very clear, The problem is due to parameters only. First go to the
> report which you include as "Subreport" in the main report. open the report
> properties, check for multi-value.
> close that remaining same. (ie string, non queried or queried, default null.)
> Go to the main report where you have placed subreport. on the subreport
> right click for properties and the parameter, this is the main culprit for
> not working.
> Parameter Name: select from the drop down.
> Parameter Value: "=Parameters!cn.Value" here just include value instead of
> Value(0)
> This should work. Let me know if it works.
> Amarnath, MCTS.
>
> "r...@.mgk.com" wrote:
> > On Mar 22, 8:07 am, r...@.mgk.com wrote:
> > > On Mar 21, 9:10 am, Amarnath <Amarn...@.discussions.microsoft.com>
> > > wrote:
> > > > on the subreport properties->parameters give
> > > > "=Join(Parameters! <ParameterName> .Value,", ") so that the multi value is
> > > > passed to the subreport as well.
> > > > Amarnath, MCTS
> > > > "r...@.mgk.com" wrote:
> > > > > ok - i've googled this and have tried everything to no avail...
> > > > > parent report has multi-value parameter: part_code
> > > > > this gets passed to subreport which has part_code setup as multi-
> > > > > valued paramter
> > > > > what is the syntax in the parent...subreport properties/parameters box
> > > > > and
> > > > > what is the syntax in the child report parameters form?
> > > > > thanks very much- Hide quoted text -
> > > > - Show quoted text -
> > > did that Amarnath ))...and i have in the parent the subreport
> > > properties/parameters: "=Parameters!PART_CODE"
> > > all i get is 'error - subreport could not be shown'......- Hide quoted text -
> > > - Show quoted text -
> > i should've said i implemented that...as well as the "=Parameters!
> > PART_CODE" in my previous reply...
> > is there some change in the SQL?...i'm just using the "....part_code
> > in (@.PART_CODE)" with the paramter setup normailly in the subreport's
> > report parameter properties......- Hide quoted text -
> - Show quoted text -
((
tried but not working...have logged incident with microsoft on this..|||On Mar 27, 12:53 pm, r...@.mgk.com wrote:
> On Mar 23, 1:21 am, Amarnath <Amarn...@.discussions.microsoft.com>
> wrote:
>
>
> > To be very clear, The problem is due to parameters only. First go to the
> > report which you include as "Subreport" in the main report. open the report
> > properties, check for multi-value.
> > close that remaining same. (ie string, non queried or queried, default null.)
> > Go to the main report where you have placed subreport. on the subreport
> > right click for properties and the parameter, this is the main culprit for
> > not working.
> > Parameter Name: select from the drop down.
> > Parameter Value: "=Parameters!cn.Value" here just include value instead of
> > Value(0)
> > This should work. Let me know if it works.
> > Amarnath, MCTS.
> > "r...@.mgk.com" wrote:
> > > On Mar 22, 8:07 am, r...@.mgk.com wrote:
> > > > On Mar 21, 9:10 am, Amarnath <Amarn...@.discussions.microsoft.com>
> > > > wrote:
> > > > > on the subreport properties->parameters give
> > > > > "=Join(Parameters! <ParameterName> .Value,", ") so that the multi value is
> > > > > passed to the subreport as well.
> > > > > Amarnath, MCTS
> > > > > "r...@.mgk.com" wrote:
> > > > > > ok - i've googled this and have tried everything to no avail...
> > > > > > parent report has multi-value parameter: part_code
> > > > > > this gets passed to subreport which has part_code setup as multi-
> > > > > > valued paramter
> > > > > > what is the syntax in the parent...subreport properties/parameters box
> > > > > > and
> > > > > > what is the syntax in the child report parameters form?
> > > > > > thanks very much- Hide quoted text -
> > > > > - Show quoted text -
> > > > did that Amarnath ))...and i have in the parent the subreport
> > > > properties/parameters: "=Parameters!PART_CODE"
> > > > all i get is 'error - subreport could not be shown'......- Hide quoted text -
> > > > - Show quoted text -
> > > i should've said i implemented that...as well as the "=Parameters!
> > > PART_CODE" in my previous reply...
> > > is there some change in the SQL?...i'm just using the "....part_code
> > > in (@.PART_CODE)" with the paramter setup normailly in the subreport's
> > > report parameter properties......- Hide quoted text -
> > - Show quoted text -
> ((
> tried but not working...have logged incident with microsoft on this..- Hide quoted text -
> - Show quoted text -
i've spoken to microsoft tech support - and they could not get it to
work...i'm assuming at this point we cannot reference a multi-value
paramenter in a subreport that rerferences it in the SQL statement
with the 'IN (@.MYPARAM) manner...too bad...will have to figure out a
work-around.|||I simulated your problem , it perfectly works for me..
Amarnath, MCTS.
"roy@.mgk.com" wrote:
> On Mar 27, 12:53 pm, r...@.mgk.com wrote:
> > On Mar 23, 1:21 am, Amarnath <Amarn...@.discussions.microsoft.com>
> > wrote:
> >
> >
> >
> >
> >
> > > To be very clear, The problem is due to parameters only. First go to the
> > > report which you include as "Subreport" in the main report. open the report
> > > properties, check for multi-value.
> > > close that remaining same. (ie string, non queried or queried, default null.)
> >
> > > Go to the main report where you have placed subreport. on the subreport
> > > right click for properties and the parameter, this is the main culprit for
> > > not working.
> >
> > > Parameter Name: select from the drop down.
> > > Parameter Value: "=Parameters!cn.Value" here just include value instead of
> > > Value(0)
> >
> > > This should work. Let me know if it works.
> >
> > > Amarnath, MCTS.
> >
> > > "r...@.mgk.com" wrote:
> > > > On Mar 22, 8:07 am, r...@.mgk.com wrote:
> > > > > On Mar 21, 9:10 am, Amarnath <Amarn...@.discussions.microsoft.com>
> > > > > wrote:
> >
> > > > > > on the subreport properties->parameters give
> > > > > > "=Join(Parameters! <ParameterName> .Value,", ") so that the multi value is
> > > > > > passed to the subreport as well.
> >
> > > > > > Amarnath, MCTS
> >
> > > > > > "r...@.mgk.com" wrote:
> > > > > > > ok - i've googled this and have tried everything to no avail...
> >
> > > > > > > parent report has multi-value parameter: part_code
> >
> > > > > > > this gets passed to subreport which has part_code setup as multi-
> > > > > > > valued paramter
> >
> > > > > > > what is the syntax in the parent...subreport properties/parameters box
> >
> > > > > > > and
> >
> > > > > > > what is the syntax in the child report parameters form?
> >
> > > > > > > thanks very much- Hide quoted text -
> >
> > > > > > - Show quoted text -
> >
> > > > > did that Amarnath ))...and i have in the parent the subreport
> > > > > properties/parameters: "=Parameters!PART_CODE"
> >
> > > > > all i get is 'error - subreport could not be shown'......- Hide quoted text -
> >
> > > > > - Show quoted text -
> >
> > > > i should've said i implemented that...as well as the "=Parameters!
> > > > PART_CODE" in my previous reply...
> >
> > > > is there some change in the SQL?...i'm just using the "....part_code
> > > > in (@.PART_CODE)" with the paramter setup normailly in the subreport's
> > > > report parameter properties......- Hide quoted text -
> >
> > > - Show quoted text -
> >
> > ((
> >
> > tried but not working...have logged incident with microsoft on this..- Hide quoted text -
> >
> > - Show quoted text -
> i've spoken to microsoft tech support - and they could not get it to
> work...i'm assuming at this point we cannot reference a multi-value
> paramenter in a subreport that rerferences it in the SQL statement
> with the 'IN (@.MYPARAM) manner...too bad...will have to figure out a
> work-around.
>|||On Mar 29, 1:24 am, Amarnath <Amarn...@.discussions.microsoft.com>
wrote:
> I simulated your problem , it perfectly works for me..
> Amarnath, MCTS.
>
> "r...@.mgk.com" wrote:
> > On Mar 27, 12:53 pm, r...@.mgk.com wrote:
> > > On Mar 23, 1:21 am, Amarnath <Amarn...@.discussions.microsoft.com>
> > > wrote:
> > > > To be very clear, The problem is due to parameters only. First go to the
> > > > report which you include as "Subreport" in the main report. open the report
> > > > properties, check for multi-value.
> > > > close that remaining same. (ie string, non queried or queried, default null.)
> > > > Go to the main report where you have placed subreport. on the subreport
> > > > right click for properties and the parameter, this is the main culprit for
> > > > not working.
> > > > Parameter Name: select from the drop down.
> > > > Parameter Value: "=Parameters!cn.Value" here just include value instead of
> > > > Value(0)
> > > > This should work. Let me know if it works.
> > > > Amarnath, MCTS.
> > > > "r...@.mgk.com" wrote:
> > > > > On Mar 22, 8:07 am, r...@.mgk.com wrote:
> > > > > > On Mar 21, 9:10 am, Amarnath <Amarn...@.discussions.microsoft.com>
> > > > > > wrote:
> > > > > > > on the subreport properties->parameters give
> > > > > > > "=Join(Parameters! <ParameterName> .Value,", ") so that the multi value is
> > > > > > > passed to the subreport as well.
> > > > > > > Amarnath, MCTS
> > > > > > > "r...@.mgk.com" wrote:
> > > > > > > > ok - i've googled this and have tried everything to no avail...
> > > > > > > > parent report has multi-value parameter: part_code
> > > > > > > > this gets passed to subreport which has part_code setup as multi-
> > > > > > > > valued paramter
> > > > > > > > what is the syntax in the parent...subreport properties/parameters box
> > > > > > > > and
> > > > > > > > what is the syntax in the child report parameters form?
> > > > > > > > thanks very much- Hide quoted text -
> > > > > > > - Show quoted text -
> > > > > > did that Amarnath ))...and i have in the parent the subreport
> > > > > > properties/parameters: "=Parameters!PART_CODE"
> > > > > > all i get is 'error - subreport could not be shown'......- Hide quoted text -
> > > > > > - Show quoted text -
> > > > > i should've said i implemented that...as well as the "=Parameters!
> > > > > PART_CODE" in my previous reply...
> > > > > is there some change in the SQL?...i'm just using the "....part_code
> > > > > in (@.PART_CODE)" with the paramter setup normailly in the subreport's
> > > > > report parameter properties......- Hide quoted text -
> > > > - Show quoted text -
> > > ((
> > > tried but not working...have logged incident with microsoft on this..- Hide quoted text -
> > > - Show quoted text -
> > i've spoken to microsoft tech support - and they could not get it to
> > work...i'm assuming at this point we cannot reference a multi-value
> > paramenter in a subreport that rerferences it in the SQL statement
> > with the 'IN (@.MYPARAM) manner...too bad...will have to figure out a
> > work-around.- Hide quoted text -
> - Show quoted text -
ok - this works when you have different names for the same parameter
in the parent and sub reports.......

passing multiple values from parent to child package

Starting with "How to: Use Values of Parent Variables in Child Packages" in the SQL Server 2005 Books Online (http://msdn2.microsoft.com/en-us/library/ms345179.aspx), it seems I need to create a separate package configuration in the child package (of type parent package variable) for each variable I want to pass from the parent to the child. Is that really so? The XML configuration file type allows me to specify any number of variables; how do I do that with the parent package variable?

For that matther, why doesn't the Execute Package Task simply allow me to specify the values of child variables (or other properties) directly? It seems SSIS has made something as trivial as a series of function calls completely opaque:

MyChildPackage(var1=1, var2="foo");

MyChildPackage(var1=2, var2="bar");

MyChildPackage(var1=3, var2="baz");

Kevin Rodgers wrote:

Starting with "How to: Use Values of Parent Variables in Child Packages" in the SQL Server 2005 Books Online (http://msdn2.microsoft.com/en-us/library/ms345179.aspx), it seems I need to create a separate package configuration in the child package (of type parent package variable) for each variable I want to pass from the parent to the child. Is that really so?

Your perception is right.

Kevin Rodgers wrote:

The XML configuration file type allows me to specify any number of variables; how do I do that with the parent package variable?

I may not be understanding you correctly; but I think with either 'parent package variables' or 'XML configuration file' you still need to create an entry in package configuration organizer for every property you want to override; so no difference there. The only difference is that in a XML file, yes you're right, multiple object-properties values can be defined.

Kevin Rodgers wrote:

For that matther, why doesn't the Execute Package Task simply allow me to specify the values of child variables (or other properties) directly? It seems SSIS has made something as trivial as a series of function calls completely opaque:

MyChildPackage(var1=1, var2="foo");

MyChildPackage(var1=2, var2="bar");

MyChildPackage(var1=3, var2="baz");

you mean to make the parent package 'aware' of the variables available in every child package...not sure how good that would be; but you can submit a suggestion to Microsoft:

http://connect.microsoft.com/feedback/default.aspx?SiteID=68

|||

Kevin Rodgers wrote:

Starting with "How to: Use Values of Parent Variables in Child Packages" in the SQL Server 2005 Books Online (http://msdn2.microsoft.com/en-us/library/ms345179.aspx), it seems I need to create a separate package configuration in the child package (of type parent package variable) for each variable I want to pass from the parent to the child. Is that really so? The XML configuration file type allows me to specify any number of variables; how do I do that with the parent package variable?

The XML config file allows you to specify lots of configurations. A configuration is for a single property only.

Kevin Rodgers wrote:

For that matther, why doesn't the Execute Package Task simply allow me to specify the values of child variables (or other properties) directly? It seems SSIS has made something as trivial as a series of function calls completely opaque:

MyChildPackage(var1=1, var2="foo");

MyChildPackage(var1=2, var2="bar");

MyChildPackage(var1=3, var2="baz");

That would mean the parent package needs to have some knowledge of what is in the pckage it is calling. That doesn't really fit with the concept of abstraction - which is what the ability to do parent-child packages is all about really (in my mind anyway). However that isn't a complete justification and I can see why this would be useful - perhaps you should submit the request at Connect?

Hope that helps.

-Jamie

Monday, March 26, 2012

Passing figures calculated in subreports

Can anybody tell me if it is possible to use a variable calculated within a subreport outside this scope (in the parent report)?

I have to list (eg) an opening balance, set of processing data, adjustments, then a closing balance.

The opening balance is a single figure in my main report, and the processing data is in the details section along with it's sum. This leaves the adjustments which have to be listed individually and then summed - done in a subreport. Can I access this sum in the body of the main report, as I need it to calculate a closing balance.

Thank you!Use shared variable|||Thanks for pointing me in the right direction. If anyone else is interested here is an article which gave a clear step by step explanation:

http://www.experts-exchange.com/Databases/Crystal_Reports/Q_21141425.html

Friday, March 23, 2012

Passing Date as aparameter to linked report from Parent report and then Dates format is Au

Hi
I need one urgent help.
When Passing Date as aparameter to linked report from Parent report,
the format of date is Automatically changing from dd/mm/yy to mm/dd/
yy. How to restrict it?
What is the solution for it in SP or rdl?
TIA.
PuneetPuneet,
Maybe you can also pass a parameter with the desired format, like "dd/mm/yy"
(this can be kept as a parameter in your application or database, so you can
change it dynamically).
Then, in the subreport, use formatting to display the date using the desired
format.
Andrei.
"appu" <ajmera.puneet@.gmail.com> wrote in message
news:1192120804.765315.73850@.o80g2000hse.googlegroups.com...
> Hi
> I need one urgent help.
> When Passing Date as aparameter to linked report from Parent report,
> the format of date is Automatically changing from dd/mm/yy to mm/dd/
> yy. How to restrict it?
> What is the solution for it in SP or rdl?
> TIA.
> Puneet
>

Wednesday, March 21, 2012

Passing connection managers to subpackages.

Is there a recommended way to pass the connection managers from the parent package to the subpackages? I also noticed that the subpackages can't reference the same configuration file as I get error messages when I try to build the solution. After I changed the configuration file for each subpackage it worked just fine. Did I miss something or is this intended to work this way?
thanks

Hi,

when you say "passing the CM's from the parent package to the subpackages", you use the ExecutePackage task or a different method?

The error with using the same configuration file is a known issue and will be addresed in a future realease

Thanks,
Ovidiu Burlacu|||I guess I'm having a difficult time understanding and even testing connection managers and configuration files. Here's what I'm trying to accomplish and am failing...

I have a project "X" with a "main" package and a another package called "child".
I have defined a generic connection manager in each of the packages (main and child ) called "SOURCEDB".

I have then created a configuration file called "connMgr". In both packages I identify this configuration file (let's just use direct configuration for now) and specify that I want the connection string, username and password configurable at load/run time.

My understanding would be that before I run the package I edit the configuration with the appropriate connection string and username so I can run the main package against different databases based on current requirements.

However, when I run the program it says that the configuration file is the same (during build) and generates an error. What is the recommended way to get around this and am I going about this the wrong way?

I have also noticed with indirect configurations that once you have to make a modification to the configuration file the file location initially specified for the configuration file is lost. Is that a bug also?

thanks
John|||1. To avoid the build error r-click the project in Solution Explorer window and choose 'Properties'. In that dialog go to 'Deployment Utility' and Set CreateDeploymentUtility to False.

If you really need deployment utility then use the XML configuration file only for the parent package and in the child package use a Parent Package variable configuration. Then in the parent package you create a variable where you can put your connection string.

2. I suggest you configure only the ConnectionString, because that will take care of User and Password as well.

3. You said "I have also noticed with indirect configurations that once you have to make a modification to the configuration file the file location initially specified for the configuration file is lost. Is that a bug also?"
Can you be more detailed in the steps that I need to follow to repro this problem?

HTH,
Ovidiu Burlacu|||Thanks for the info. I'll try answer 1. I tried using only connection string but I have noticed that the password doesn't get stored in the configuration file. When I change the connection string the job will fail the next time as the password isn't valid. How do I get the password changed and where when using the configuration file?

3. When I create an indirect configuration file I start first by creating the direct configuration which I point to a filename and directory. Once I have that created I go back and specify the env variable to use for this configuration.

Let's say I then have to make a modification to the configuration file. If I go back and uncheck the "Configuration location is stored in an environment variable" to make configuration changes I have to check the other option but the file name and directory are no longer there. I then have to go search for the configuration file location which is not too much pain for me but for someone else it could be who is administering the packages... It would be nice to retain the filename and location in that field.

thanks|||

With respect to your answer 1 I assume that's just a current workaround, correct? I assume that this is a bug and will be fixed in the near future ...

|||Yes this is a workaround, and as I specified in my first reply the bug will be addressed in a future release.

Thanks,
Ovidiu|||Do you have any thoughts on the password problem I'm having? I'm not sure if you saw the post from this morning ...
thanks|||

I tried your scenario but when I went in the XML config file and added Password=<my_password> to the ConnectionString the package executed just fine.

HTH,
Ovidiu

|||I was under the assumption it would add the password automatically. There is one slight problem with this. If you add the password manually it gets overridden the next time you regenerate the configuration file. You'll have to remember to add the password manually every time!!!|||Adding the password automatically is a security violation. (disclosure of confidential information). The user must enter the password manually, this way he will make sure that the file will get the appropiate ACL's

Thanks,
Ovidiu|||I did notice that if you use the manifest to install your packages on the server that it will automatically add the password to the config file. That would seem to contradict the above statement somewhat.|||

Can you describe the issue in more detail?

What password is saved in the config file?

Thanks,
Ovidiu

|||

If you double-click on the manifest file and go through the package installation wizard you can add the values for password and username if that's what you have checked off in the config file. It will then go ahead and add the password='password' in the configuration file.

Someone else at our company didn't specify connection string but username and password and it seems to add the password in the configuration file. However, if you use connection string it won't.

|||

This falls into what I said: "The user must enter the password manually"

If the user enters the password value in the wizard I must save that value into the configuration file because this is what the user want. Is not that we automatically save the password in the config gile.

Ovidiu

Tuesday, March 20, 2012

Passing a variable between a parent and child package doesn't work

Has someone managed to pass successfully a variable from a parent package to a child package? I’ve tried a zillion permutations and I can’t get it to work. The strange thing was that I was able to successfully do this with pre-RTM builds. Basically, what I am trying to do is:

  1. The parent package has a variable, e.g. ExecutionID which I set using a script to System::ExecutionInstanceGUID. I verified that the variable is set correctly by dumping it to a SQL Server table.
  2. I created a child package variable with the same name.
  3. In the child package, I’ve created a parent package configuration that points to the ExecutionID variable.
  4. I am trying to read the variable in a Derived Column Task in which I have a column linked to @.ExecutionID.

This doesn’t work. Step-by-step instructions from someone who managed to concur this will be greatly appreciated.

Oh, I didn’t have any luck hitting a breakpoint in a script task inside a child package with both in and out of process execution also.

Never mind. My configuration got messed up. I am still not sure what needs to be done to debug a child packge though. Ideas?

Passing a value from parent report to subreport

This is what I want to do:
I have the following report layout
Day Sales Expenses
1 10 2.5
2 12.5 3.2
3 10 4
4 14 7
5 12 5
When a user clicks on a day number a subreport will launch with layout
below:
Day Product Sales Expenses
* Core 2 .45
* Cobrand 2 1
* Franchise 5 1
* Other 3 3
Has anyone ever developed something like this that can give me some
help. I can pass parameters from the parent report to the subreport, I
just don't know how to pass a click action value from the parent report
to the subreport as a parameter.
Thanks in advanceHi John,
Yes have worked on it.
1. You need to create two reports. (one with day, sales, expenses 2nd with
day prod, sales,exp)
2. On the main report. go to the layout (expect u will place it on a table)
and on your "day field" just right click for properties. On the navigation
click hyperlick.
Jump to report.
3. On jump to report option select your detail file and give the parameters
if exists.
There you go you will get you reports. you will have a automatic previous
button to return it to the parent report. If you want to place a back button.
you can place a "back" textbox and give the hyperlink to the parent report.
So th users can click the back button to come to the parent. Ofcourse this is
optional.
Any doubts let me know
Amarnath
"john.r.carter@.bankofamerica.com" wrote:
> This is what I want to do:
> I have the following report layout
> Day Sales Expenses
> 1 10 2.5
> 2 12.5 3.2
> 3 10 4
> 4 14 7
> 5 12 5
> When a user clicks on a day number a subreport will launch with layout
> below:
> Day Product Sales Expenses
> * Core 2 .45
> * Cobrand 2 1
> * Franchise 5 1
> * Other 3 3
> Has anyone ever developed something like this that can give me some
> help. I can pass parameters from the parent report to the subreport, I
> just don't know how to pass a click action value from the parent report
> to the subreport as a parameter.
> Thanks in advance
>|||Amarnath,
Thank you for you reply. I have one more question. Is there a way to
filter the subreport table based on the day the user cloicked on the
parent report. Meaning, if a user clicks the 5th, the subreport will
launch with only the subreport table loaded w/ data for the 5th, no the
entire month.
Thanks in Advance,
John C|||Hi John,
Yes it works like this. when you click it takes the parameter of the clicked
field. In this case 1,2,3,5 etc.. so the sub rport takes 5 as the parameter.
Hope you have given the parameter on the "jump to report" report.
Amarnath.
"john.r.carter@.bankofamerica.com" wrote:
> Amarnath,
> Thank you for you reply. I have one more question. Is there a way to
> filter the subreport table based on the day the user cloicked on the
> parent report. Meaning, if a user clicks the 5th, the subreport will
> launch with only the subreport table loaded w/ data for the 5th, no the
> entire month.
> Thanks in Advance,
> John C
>|||Hello Armanath,
I have a report with a subreport. Both reports use the same parameters.
The user is prompted for the parameters, and they can be null. I'm
saving the parameter values in text fields on the main report and pass
them via the jump to report link. (I tried to use the original
parameters and pass them directly to the subreport, but that caused
errors and I therefore now save them on the report) I have created the
parameters for both reports,just as you described. But the sub report
does not render when one of the parameters is null. I have set the
parameters on the subreport to accept null values. I tried to set the
default value to null for the subreport parameters, but then it said
that "null" is no longer valid and I should use System.DBNull instead.
When I did that, it says that DBNull is a type in System and cannot be
used (or something similar).
Do you know what I need to do to be able to run the subreport with some
or all of the parameters being null? The error I get says" The value
for the report parameter [whatever parameter is null] is not valid for
it's type".
I would be very grateful if you have any idea of what needs to be done.
Thank you,
Mimi|||Hello Armanath,
I have a report with a subreport. Both reports use the same parameters.
The user is prompted for the parameters, and they can be null. I'm
saving the parameter values in text fields on the main report and pass
them via the jump to report link. (I tried to use the original
parameters and pass them directly to the subreport, but that caused
errors and I therefore now save them on the report) I have created the
parameters for both reports,just as you described. But the sub report
does not render when one of the parameters is null. I have set the
parameters on the subreport to accept null values. I tried to set the
default value to null for the subreport parameters, but then it said
that "null" is no longer valid and I should use System.DBNull instead.
When I did that, it says that DBNull is a type in System and cannot be
used (or something similar).
Do you know what I need to do to be able to run the subreport with some
or all of the parameters being null? The error I get says" The value
for the report parameter [whatever parameter is null] is not valid for
it's type".
I would be very grateful if you have any idea of what needs to be done.
Thank you,
Mimi|||Hello Armanath,
I have a report with a subreport. Both reports use the same parameters.
The user is prompted for the parameters, and they can be null. I'm
saving the parameter values in text fields on the main report and pass
them via the jump to report link. (I tried to use the original
parameters and pass them directly to the subreport, but that caused
errors and I therefore now save them on the report) I have created the
parameters for both reports,just as you described. But the sub report
does not render when one of the parameters is null. I have set the
parameters on the subreport to accept null values. I tried to set the
default value to null for the subreport parameters, but then it said
that "null" is no longer valid and I should use System.DBNull instead.
When I did that, it says that DBNull is a type in System and cannot be
used (or something similar).
Do you know what I need to do to be able to run the subreport with some
or all of the parameters being null? The error I get says" The value
for the report parameter [whatever parameter is null] is not valid for
it's type".
I would be very grateful if you have any idea of what needs to be done.
Thank you,
Mimi|||Nevermind. The way to solve it is to insert
<Omit>=Iif(Parameters!EndDate.Value is Nothing, True,False)</Omit>
under each parameter in the main report.
see
http://www.sqlmonster.com/Uwe/Forum.aspx/sql-server-reporting/5825/The-value-provided-for-report-parameter-StartDate

Saturday, February 25, 2012

Pass back error count to Parent pkg

I am trying to pass back the number of errors encountered by a child package to the Parent package. I have a script within the child package, which will set the value of the Parent package's variable (ChildErrCount). However, I have no idea how to access the Child package's Errors collection to get a count.

Any ideas? Has someone figured out a way to reference the current package's properties (besides what's available from Dts.* ?

Thanks!

See the following topic:

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=20103&SiteID=1

|||I should clarify ... I want to know how to get the number of Errors. I already know how to pass the value back.
|||

Why don't you want to use the error information available through dts.*?

Here is a useful link (although it uses the dts.* approach):

http://www.developerdotstar.com/community/node/327

NOTE: you can then push these values to a variable and pass it up to the parent package...

|||

OK, ignore any parent/child aspects of my question.

Let's say your package has a bunch of errors, and sometimes you get a warning message:

The Execution method succeeded, but the number of errors raised (6) reached the maximum allowed (1);

I want to know how to get that "6" value, (i.e. I don't need to know any specific error info). It's obviously stored within the package -- I just want access to it.

Initially I was thinking I could code my way into the Package and retrieve the Errors Collection; then use its Count property:

CurrentPackage.Errors.Count

But, there's no easy way to do that, which is why I'm here.

|||

You could put something in the OnError eventhandler that simply increments a variable every time it executes.

If another way exists, I don't know about it. perhaps Microsoft do. [Microsoft follow-up]

-Jamie

|||

The Package object support the "Errors" property which you can call the "Count" method. Unfortunately you cannot get access to the package object inside script task. This is a design decision. The only way to get to property is via the programming object model.

I am not aware of any workaround beside Jamie's suggestion.

|||Since you are calling this from a parent package, you could run the child package through a script task, instead of the Execute Package task. That way, you could access the Package.Errors property of the child package.|||

That's a neat idea, John. I hadn't thought of that. I was hoping to avoid recalculating a count that already existed, but for now Jamie's workaround seems to be the simplest solution so I'll go with that.

Thanks to all!

Pass back error count to Parent pkg

I am trying to pass back the number of errors encountered by a child package to the Parent package. I have a script within the child package, which will set the value of the Parent package's variable (ChildErrCount). However, I have no idea how to access the Child package's Errors collection to get a count.

Any ideas? Has someone figured out a way to reference the current package's properties (besides what's available from Dts.* ?

Thanks!

See the following topic:

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=20103&SiteID=1

|||I should clarify ... I want to know how to get the number of Errors. I already know how to pass the value back.
|||

Why don't you want to use the error information available through dts.*?

Here is a useful link (although it uses the dts.* approach):

http://www.developerdotstar.com/community/node/327

NOTE: you can then push these values to a variable and pass it up to the parent package...

|||

OK, ignore any parent/child aspects of my question.

Let's say your package has a bunch of errors, and sometimes you get a warning message:

The Execution method succeeded, but the number of errors raised (6) reached the maximum allowed (1);

I want to know how to get that "6" value, (i.e. I don't need to know any specific error info). It's obviously stored within the package -- I just want access to it.

Initially I was thinking I could code my way into the Package and retrieve the Errors Collection; then use its Count property:

CurrentPackage.Errors.Count

But, there's no easy way to do that, which is why I'm here.

|||

You could put something in the OnError eventhandler that simply increments a variable every time it executes.

If another way exists, I don't know about it. perhaps Microsoft do. [Microsoft follow-up]

-Jamie

|||

The Package object support the "Errors" property which you can call the "Count" method. Unfortunately you cannot get access to the package object inside script task. This is a design decision. The only way to get to property is via the programming object model.

I am not aware of any workaround beside Jamie's suggestion.

|||Since you are calling this from a parent package, you could run the child package through a script task, instead of the Execute Package task. That way, you could access the Package.Errors property of the child package.|||

That's a neat idea, John. I hadn't thought of that. I was hoping to avoid recalculating a count that already existed, but for now Jamie's workaround seems to be the simplest solution so I'll go with that.

Thanks to all!