Airtable as ERP - for creating orders?

Hi,
I am total new for airatable. So sorry in advance if it was asked before. But I was not able to find it.

I am trying to figure out if Airtable could be use as kind of an ERP. Basically create orders by our sales and than “do automate stuff around it”.

Basically I am starting to create table with Form that they would fill up/use with new order.

Now to question. Is it possible to create Unique ID that would have specific set of numbers and logic around it for each order?

For example:

  • Every order would have unique number
  • Every order number is exactly 10 lenght
  • First two numbers are fixed (11-----)
  • Third and fourth nubmer are last two digits of year (1122…)
  • Fifth number office number (Karen is from Europe office so it would be fixed “5” but Bob is from America so he would have fixed “6”, etc…
  • last five numbers are always unique number always increased by 1 from 00000 to 00001, 00002, etc…

Can this be done in airatable?

Thanks and have a nice day,
Matt

All very possible & a common use case.

your name field would be a formula which took all that into account.

Hi @Matej_Skarka,
You can absolutely do this in Airtable. I am making a few assumptions, if I am incorrect let me know and I can adjust.
The year is the date the order was created, not just the current year.

If you do not have it already you might want a field of type Single Select and add, Karen, Bob and whoever else, name this what ever you want but in my code I named it Office.
Create a new field of type: Autonumber and name it autonumber, this field can now be hidden if you dont want to see it.
Create a new field of type: Formula and paste this into the formula editor and name this Order Number

'11'&
DATETIME_FORMAT(CREATED_TIME(),'YY')&
SWITCH(
  Office,
  'Karen', 5,
  'Bob', 6
)&
REPT(
    '0',
    5-LEN(
        {autonumber}&''
        )
    )&
{autonumber}

The autonumber field will increment for every new row that is created and will not deduct if a row is deleted. If you need to reset it at any time (after testing) delete it and recreate it to reset the counter.

That looks like the direction I am looking for. I will explore this bit more.

Next questin - Can I pair the “Colleague names” automatically to sign in user in Airtable?

But even without it looks promising. Thank you very much

Yes, will the colleague be added to the order manually by someone else, or will the colleague be the person that creates the order?

If the later we will adjust some of the formula. First create a new field of type Created By. This will give us the person that creates the record. Since a person can put in any name and change it too and there can be more than one Karen, it might be a good idea to use their email address to rule out those possibilities. I do not know of another way to get the User email from Airtable other than automation or scripting. So create another empty Short Text field and name it Creator Email

Now we need to set up an automation to get the address:
Trigger - When a record is created in our table
Action - Update a record, on the same table, use the Record ID from step 1, Field Creator Email place the Created By Email.

SWITCH(
  Office,
  'Karen', 5,
  'Bob', 6
)

to this

SWITCH(
  {Creator Email},
  'karen@company.com', 5,
  'bob@company.com', 6
)

Hey Vivid-Squid,
you are great. This is the way :slight_smile: Just need to play with it a bit.

The user who is logged in is the one who is creating the order and is the one who i need to get to the table. So I think your suggestion is correct.

Thank you very much!

This topic was solved and automatically closed 15 days after the last reply. New replies are no longer allowed.