cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
LuisGuzman98
Advocate II
Advocate II

Compose and join a string

Hello, 

 

I want to separate a name and then unify it with a period. For example: 

 

Luis Guzman (into) -> luis.guzman

 

The input for composing it would come from the outputs of the trigger 'When an item is created in sharepoint' variable called 'Owner Alias'. Like this:

image.png

 

 

 

 

 

 

 

3 ACCEPTED SOLUTIONS

Accepted Solutions
abm
Super User III
Super User III

Hi @LuisGuzman98 

 

Please see below.

 

output1.png

 

Here I have used two split functions.

 

split('David Smith', ' ')[0].split('David Smith', ' ')[1]
 
When you add the expression use a period between the split expressions.

 

This is my output

 

output2.png

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blogPower Automate Video Tutorials

View solution in original post

Hi @LuisGuzman98 

 

What's the data type of your column?

 

Another way you could do is use two compose action steps. First compose just map the owner alias field. Second compose use the split. That might work.

 

Let me know how it goes.

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blogPower Automate Video Tutorials

View solution in original post

Hi @LuisGuzman98,

 

Just like @abm said, you can use the Compose action to store the Owner alias before you use the expression, I have a way could also share with you:

toLower(replace(outputs('Compose'),' ','.'))

Annotation 2019-09-25 163531.png

 

Annotation 2019-09-25 163738.png

Best Regards,
Community Support Team _ Lin Tu

View solution in original post

11 REPLIES 11
ScottShearer
Super User III
Super User III

@LuisGuzman98
You'll want to use the split and concay expressions - I will provide an example later today.
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Scott
abm
Super User III
Super User III

Hi @LuisGuzman98 

 

Please see below.

 

output1.png

 

Here I have used two split functions.

 

split('David Smith', ' ')[0].split('David Smith', ' ')[1]
 
When you add the expression use a period between the split expressions.

 

This is my output

 

output2.png

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blogPower Automate Video Tutorials

View solution in original post

Hey @abm!

 

Thanks! I wanted to that for the 'Owner Alias' value of the item created in SP. I was entering this small code for capturing the dynamic variable from the trigger: 

 

split(triggerBody()?['Owner Alias'], ' ')[1]
 
But it doesn't work, the following message error is shown in the result:
 
image.png

 

How can I capture that dynamic variable for the split function?

 

 

 

Hi,

 

Could you post your flow screenshot?

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blogPower Automate Video Tutorials
abm
Super User III
Super User III

Hi @LuisGuzman98 

 

Try this.

output3.png

 

Here I am checking the index is greater than 1 then use the split index 0 and 1 under the compose statement. 

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.

 

Thanks

 

 



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blogPower Automate Video Tutorials
abm
Super User III
Super User III

Hi @LuisGuzman98 

 

The reason for your earlier error is most likely the value is null here. Use the below syntax so that if the value is null then it won't throw an exception.

 

split(triggerBody()?['Owner Alias'], ' ')?[1]

 

You could also try my earlier suggested solution.

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blogPower Automate Video Tutorials

@abm

 

It's weird if I provide just the owner alias dynamic variable in the compose action it does read it. It isn´t null.

 

Dynamic variable providedDynamic variable providedoutputoutput

This is my flow configuration. I try it with the latest idea:

 

image.png

 

It ain´t working. The error is: 

null parameter value errornull parameter value error

I really don´t know why is it reading the value as null, because it does read it when it is just the dynamic value. 

 

Please help, thanks

Hi @LuisGuzman98 

 

What's the data type of your column?

 

Another way you could do is use two compose action steps. First compose just map the owner alias field. Second compose use the split. That might work.

 

Let me know how it goes.

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blogPower Automate Video Tutorials

View solution in original post

Hi @LuisGuzman98,

 

Just like @abm said, you can use the Compose action to store the Owner alias before you use the expression, I have a way could also share with you:

toLower(replace(outputs('Compose'),' ','.'))

Annotation 2019-09-25 163531.png

 

Annotation 2019-09-25 163738.png

Best Regards,
Community Support Team _ Lin Tu

View solution in original post

Hey Thanks! @abm,

 

That worked, I captured the content of the owner alias through a first compose action - > then I created a variable and assigned the output of the first compose as the value - > and the splited the variable. 

 

Great solution!

Hi @LuisGuzman98 

 

Fantastic. Thanks for letting me know.

 



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blogPower Automate Video Tutorials

Helpful resources

Announcements
Process Advisor

Introducing Process Advisor

Check out the new Process Advisor community forum board!

MPA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

MBAS Attendee Badge

Claim Your Badge & Digital Swag!

Check out how to claim yours today!

Users online (42,920)