Skip to main content
Best answer

How to remove the last item from a comma-separated value in a QuickBooks invoice using Zapier


I am trying to update a quickbooks invoice by adding a line item. This has already been made very difficult by zapier by erasing all the data on an invoice if you try to add a line item. So i’m trying to use formatter to append my new line item data to existing, so that the data is added and not overwriting. However, the Amount field on the invoice includes the Total Amount as it’s own value, which throws off the alignment of all the other fields I am adding. I am trying to remove the last value of the Amount value set so that I can add my new line item amount to the end, but I am struggling with the split text formatter tool. When I do Separator as comma, and the segment index as last, it still returns all values. If I do second to last, it returns no values. This is a 16 line item invoice. I tried using the Total Amount itself as the separator, which worked, but this is not a true solution, as if there is only one line item on the invoice, it could erase that. This seems to be a pretty normal function to be seeking so I’d be surprised if it’s not available - what am I missing 

Best answer by Troy TessaloneBest answer by Troy Tessalone

Hi ​@jadecol 

This may help: 

 

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

3 replies

Troy Tessalone
Forum|alt.badge.img+14
  • Zapier Expert
  • 30887 replies
  • Answer
  • February 20, 2025

  • Author
  • Beginner
  • 2 replies
  • February 20, 2025

@Troy Tessalone This literally saved my life thank you so much!!!


SamB
Community Manager
Forum|alt.badge.img+11
  • Community Manager
  • 7412 replies
  • February 21, 2025

Yay! 🎉 That’s great to hear, ​@jadecol. Huge thanks to ​@Troy Tessalone for sharing such a great resource—this will definitely come in handy for others too! 🧡

Feel free to reach back out to the community anytime if you need help again. Happy Zapping! ⚡