specifying a parameter instead of explicit value in process task - sql

I have a process task:
I'm wondering whether it's possible to pass something like this into it:
$Package::targetLocation
Thank you for your guidance,.

You should be able to do this with the Expressions tab, create a new expression against the Arguments property and assign this to your user variable.

Related

Is there a way to add a parameter during run-time?

At the Manual Judgement stage we were hoping we could enter a value, continue and pass that value onto Jenkins with "${#judgment("Manual Judgment")}". We can pass the predefined option but can't enter a new one. Is there a way of getting this to work or an alternative method?
One way to achieve this is by using pipeline parameters.
In configuration stage of the pipeline, add a parameter (say Name="jenkins") and configure the parameter's options (like default value, required or not)
Before the manual judgment step, create a Evaluate Variables stage. In the stage configuration, create a variable named "jenkins" with the value ${parameters.jenkins}
In manual judgment's options, add the variable ${jenkins}
Now, during the manual judgment stage, it would show an option with the value provided to the pipeline.
You could also join Spinnaker's slack here: https://join.spinnaker.io/

How can I make parameters optional?

I need some help with pentaho report designer.
I've used some parameters to filter my data, but, it seems that I'm obliged to filter on these parameters to show data on my charts.
So, this is what I want, I need to make my parameters optional. It means that I want to show global views even if I don't select a parameter.
Any thoughts?
Untick the mandatory checkbox in the parameter settings dialog.
You must create a hidden parameter; Let's call it "Flag" that tests whether the parameter are set, by using this post-processing formula.
=OR(ISNA([date_from]); ISNA([date_to]))
and then in your query reference that new parameter:
Select .....
where ${Flag} = TRUE OR (date between ${date_from} and ${date_to})

Specifying multiple MergeSection values when using LINK task on MSBuild

Is there anyway to specify more than one MergeSection value for the MSBuild LINK task? (The MergeSection param is the same as the /merge param for link.exe)
http://msdn.microsoft.com/en-us/library/ee862471.aspx
When calling link.exe you can specify more than one /merge value, but that doesn't seem possible with the MergeSection parameter.
So far the only way I can see to make this work is by using the AddtionalOptions param, but I'm hoping there's a better way to implement this parameter.
Thanks
I think you may have to use AdditionalOptions.
In the Link task the MergeSections property is a string value, not an array, so you can only set one string. Link.exe does not seem to allow you to pass multiple pairs in one command line parameter, you must specify a separate MERGE command line parameter for each pair. The Visual Studio property page only allows a single string for the MergeSections property.

SSIS set variable at runtime

Anyone know how I can change a SSIS variable at runtime?
I have a variable User:SkipStuff
I want to set this based on a condition during a for loop container
Use Expression Task instead. In the "Expressions" pane, put the variable to set on left, then equates it to the intended value.
#[User::VariableToSet] = some expressions...
You can add a Script task. Add your SSIS variable(s) to the ReadWriteVariables property in the Script Task Editor.
You can reference the variable(s) in your script using the following format: Dts.Variables["MyCaseSensitiveVariableName"].Value
Lots of ways really, but the one I use most frequently is to use an execute SQL task and set the result set to single row and then put the results set into the variable.

Is there a way to use default arguments that are the result of a function call in VB.NET?

I have a whole slew of database access functions which assume a particular connection string. Within my application I call
myList = DB_MyTable.GetTableItems()
and within GetTableItems() I have something like
Dim connection As SqlConnection = MyDB.GetConnection
So the connection string is in one place in the code, and I call a method to get it.
What I'm running into now is I want to reuse the same database functions, but with a different connection string. I can rewrite all of the functions like DB_MyTable.GetTableItems() easily because they're generated from a script, but within the main application code I'll need to take care of every function call that now needs to know what connection string I want to use.
I tried changing the arguments to GetTableItems() like this:
Public Shared Function GetTableItems(Optional ByVal useThisString as String = MyDB.GetConnection) As List(Of MyItems)
in hopes of being able to pass in, by default, the string I'm already using in most of the code, but I got an error saying that the default value had to be a constant expression. This would mean peppering a specific connection string everywhere, which I don't want to do.
Is there a way to accomplish what I'm after, or do I need to make the connection string a required argument and change all of the calls in my application to match the new signature?
Thanks as always!
Can you make your default value an empty string? Then, in your functions, if the useThisString variable is blank, then use default, else use the one you passed in? A littler dirtier, but just barely.