Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 5280 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies
Posted

This is my first post, so any help will be greatly appreciated!

I have a solution I have created and I need to move data from a text field to a portal row.

My text field has style codes separated by a semi-colon. This is the format that our website requires to handle our data. There may be between 5 and 500 styles codes per product. I have created a separate table that I want to move each occurrence of a style code into a record in that other table.

Example:

Product 1234 has style codes "abc;abd;abe;abf;abg" assigned to it in the text field "style_codes". I want to have those codes end up as records in a related table.

How do I get the text in my style code field to be moved into a portal row? What solutions do you suggest?

Thanks!

Posted (edited)

I believe the easiest way is to define a repeating calculation field with 500 repetitions (so that each code ends up in its own repetition) =


Let ( [

i = Get (CalculationRepetitionNumber) ; 

v = Substitute ( Extend ( style_codes ) ; ";" ; ¶ )

] ;

Case (

i ≤ ValueCount ( v ) ;

GetValue ( v ; i )

)

)

Then import the ProductID and the calculation field into the new table, while splitting them into individual records.

Edited by Guest
Added the code

This topic is 5280 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.