I have a scenario of passing the notebook output to loop to fetch 4 Id's to a variable but got below error. can someone help me on how to achieve this. Thanks in advance.
enter image description here
enter image description here
enter image description here
enter image description here
The Item section in your ForEach activity should be like:
#{activity(‘Notebook1’).output.runOutput}
When accessing that item with the ForEach, use Set Variable activity to read the output from the Notebook and **create a variable with Array type** by clicking on + New` under Variable tab.
Now use #item().SurveyID[0] because the variable holding data is an Array type so it can be selected. In your case, since the SurveyID is a string type and you cannot implement property selection on string type because it isn’t supported.
Related
My goal is to save to a json file, the parameters passed in a Pipeline.
I added the parameter to the pipeline
And with a copy activity I'm trying to save the value to a json (in a blob storage). The problem is that I can save as string in a json, but I cannot as integer
Using dynamic content #int(pipeline.parameters...) doesn't work.
Is it possible to save in an integer format?
thanks
I tried to cast as dynamic content and also importing the schema from mapping schema, the type is still a string
I tried same scenario and getting same error as Expression of type int dose not match the field value.
Even we provided direct value int in additional column it is taking it as string.
The work around is to use dataflow with derived column and data flow parameter and pipeline parameter as shown below:
First create pipeline parameter with integer type.
Create data flow and add source file to it then take derived column and create column and give value as parameter1.
Click on Open expression builder >> parameters >>create new.
Give name to parameter as parameter1 and type as integer and click on create.
Then come back to pipeline cand click on dataflow activity >> Parameters >> click on dynamic expression below value box >> select Pipeline expression and pass the pipeline parameter which we created.
OUTPUT
Taking as int
I'm trying to run a pipeline that results a select with where be the system triggername system output.
I've tried to use :
#concat(concat(concat(concat('select * from ',item().DB_CARGA,'.',item().SC_CARGA,'.',item().tb_carga, 'where ' ,item().DS_CARGA ,'=', string(pipeline().TriggerName)))))
But I'm getting the following error:
Could anyone help me with the right syntax?
I reproduced this and got similar error when I used your syntax.
In your dynamic expression, there should be a space between table name and where and also trigger name should be enclosed in single quotes.
Please go through the below procedure to resolve the error.
First, I have a lookup activity which will give database name, table name and SQL table column(trigger column name). Give this to Foreach.
I have created sample tables with trigger_column column and gave some values.
In pipeline I have created trigger with same name mytrigger. Inside Foreach for my demo I have used lookup query. You can use your activity as per the requirement.
Dynamic content:
You can do this with single concat function.
#concat('select * from ',item().database,'.',item().table_name, ' where ' ,item().trigger_name ,'=','''',string(pipeline().TriggerName),'''')
This will give the SQL query like this when Executed.
Output when triggered:
I am using PowerApps Canvas for the first time. I have created two screens. One has a gallery connected to an excel sheet. It displays the table contents from the excel file. And the second screen has some input text fields. I want to enter values in these fields and click on submit, so that when I go to the other screen I can see this new record in the gallery. I want to use the collect function for the submit button but it is showing problem with using Record1 (name of the global variable in which I am storing the excel table). It says the specified data source cannot be used.
Collect(Record1,
{
AgentName:TextInput1.Text,
ID:TextInput4.Text,
Shift:TextInput2.Text,
Weekoff:TextInput3.Text
}
)
I am setting Record1 as a global variable in the onStart property.
Set(Record1,Table1);
Edit: I ran onStart and the error is not there but new record isn't being displayed on the gallery. There is an error with setting the global variable Unexpected Characters. The formula contains 'Ident' where 'Data' is expected.
Making a global variable wasn't required. I just used the excel table directly in the other screen and the collect function works now.
You want to store your input into your excel right? You need patch instead of collect. Collect is for local storage, patch creates an item in the datasource.
I am setting a List/Record type script parameter and Select one value (Display name: Sample Company, Id: 5) as a default. I'm using
nlapiGetContext().getSetting('SCRIPT','custscript_my_parameter');
to get the value. it returns the id(in my case 5) of the List/Record. But I need the display name(in my case Sample Company) of the List/Record. Anyone, Please advice to get it.
Thanks in advance.
Why don't you create another script parameter of type Free-Form Text and set the display value for the field to retrieve on the other side. You could use something like below
nlapiGetContext().getSetting('SCRIPT','custscript_my_parameter_text');
Otherwise if you want to get the display value with the id you have then, you probably need to load the record and get the company name(text).
Looking over the documentation of nlobjContext#getSetting, I do not see a way for you to get the text value of the select field. It looks like you will need to retrieve the ID from the script setting, then perform an nlapiLookupField on the appropriate record to retrieve the appropriate text value.
how can i make a report in Cognos 10 using render variable so that i can achive results on same page. Report should have a dropdown choice for user to view output in LIST or CROSTAB.
There are a few ways i'll show one that you are already very close to getting.
Create a Variable named something like "vReportFormat" that say does a case on the parameter that determins the format
Example
Variable Name: vReportFormat
Case
When ?Param? = 'List'
Then 'List'
Else 'Crosstab'
End
In the Render Variable Property of the List select your newly created variable "vReportFormat" and then select only the output value "List" that you created when you made the variable. By selecting only List when the report runs it will evaulate the variable first and then the list will only render if the output value is 'List' - Repeat this variable assignment for the crosstab but of course pick 'Crosstab' as the output value.
There are other variations like creating two report pages and using the render variable on the Page object itself - works the same exact way.
Hope this helps.