# Generating Order Numbers, Payments, and Email Templates

**URL:** <https://community.glideapps.com/t/generating-order-numbers-payments-and-email-templates/68515>\
**Category:** Ask for Help\
**Created:** [December 8, 2023, 8:43pm UTC](https://community.glideapps.com/t/generating-order-numbers-payments-and-email-templates/68515 "2023-12-08T20:43:33Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![Jeff\_Hager](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/jeff_hager/32/43_2.png) [@Jeff\_Hager](https://community.glideapps.com/u/Jeff_Hager)\
**Post date:** [December 8, 2023, 9:43pm UTC](https://community.glideapps.com/t/generating-order-numbers-payments-and-email-templates/68515/2 "2023-12-08T21:43:53Z")

</div>

> [@bman737](#):
>
> What is the most efficient way to generate a unique 5 digit order number (ideally sequential)?

This is the best way to do it strictly within Glide.

> [@How do I create an auto-incrementing row number with Glide Tables?](https://community.glideapps.com/t/how-do-i-create-an-auto-incrementing-row-number-with-glide-tables/39572):
>
> This is a question that comes up a lot, so creating this topic to use as a reference. Typically, there are two distinct use cases when it comes to auto-incrementing row numbers. Use Case 1: – We need to generate a Part Number, or an Order Number, or an Employee ID. Once the number is generated, it should never change, even if rows are deleted. – The general approach for this use case is to maintain a static counter, use it to craft a suitably formatted ID, and increment it by one every time…

@Darren_Murphy could probably confirm, but I believe there would still be an issue with duplicate numbers if multiple users generated an order number at the same time. In that case, you would probably have to use an external service to sequentially process and increment the numbers.

---

_[View the full topic](https://community.glideapps.com/t/generating-order-numbers-payments-and-email-templates/68515)._
