Skip to main content
Solved

PadLeft function not working on Import Scenario


Forum|alt.badge.img
  • Jr Varsity III
  • 11 replies

I have a simple import scenario that I am using as a test that is being used to populate customer contact records. In the import scenario I am using the =PadLeft([PostalCode],5,’0’) to pad out any of postal codes that have a leading zero so that they will pass validation. When I run the import scenario it looks like the code isn’t even running. I am not sure if I am doing something wrong or if I am missing a small detail that is preventing the code from running. The code passes the validation test so I don’t think it is a syntax issue. I have attached the data provider, the excel spreadsheet and the import scenario. Any help would be greatly appreciated.

Best answer by mtcook

I figured it out. I was under the mistaken assumption that the code would update the data in the grid once Prepare was run, and show the postal code padded out. From what I have been able to determine the Prepare grid shows just the raw data from the data provider and not with the transformation that the code would provide. When I ran the import scenario the postal codes did go into the contact screens padded out. 

View original
Did this topic help you find an answer to your question?

2 replies

Forum|alt.badge.img
  • Author
  • Jr Varsity III
  • 11 replies
  • Answer
  • November 30, 2023

I figured it out. I was under the mistaken assumption that the code would update the data in the grid once Prepare was run, and show the postal code padded out. From what I have been able to determine the Prepare grid shows just the raw data from the data provider and not with the transformation that the code would provide. When I ran the import scenario the postal codes did go into the contact screens padded out. 


Chris Hackett
Community Manager
Forum|alt.badge.img
  • Acumatica Community Manager
  • 2768 replies
  • November 30, 2023

Thank you for sharing your solution with the community @mtcook!


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings