
Below find the explanation to this formula in 5 steps. There is one more formula (a supporting formula) in cell L2. Multiple Vlookup Combined for Creating Unique Identification Codesįinal Formula: =ArrayFormula(if(A2:A="","000"&ifna(vlookup(B2:B,G2:H,2,false))&ifna(vlookup(C2:C,I2:J,2,false))&L2:L)) In addition to that, I have used a running count formula.īelow is the formula that I have used in example 1 above (to be inserted in cell D2). To create unique IDs as above, I have actually used multiple Vlookups and combined them.

#GOOGLE UUID GENERATOR HOW TO#
ID Formula and How to Modify It for a Different Lookup Table The last digit represents the occurrence and I’ll come to that later. Let’s see how to decode it with the help of a lookup table. In this example, to explain, I am taking the ID from cell E5 which is 0001121. Creating Unique Readable IDs for Assets Purchased The formula in column D (I mean the array formula in cell D2 which I am going to provide later in this tutorial) will consider the newly added records while generating the codes. Note: You can add more author names and genres within the lookup table. That means you can read the unique IDs with the help of another table (lookup table) maintained in the same sheet or another sheet.įor example purpose, I have maintained the lookup table within the same sheet. The number 3 represents the author code, 2 represents the genre and 1 represents the number of occurrences of the book from the same author under the same genre. What about the number 321 then and how it is becoming a unique readable ID? In this, the three leading zeros don’t convey any meaning. As per my formula, the generated readable unique ID is 000321 (cell D5). In row # 5, you can see the necessary details of the book to generate the unique item numeric code.

Let me first explain one of the ID generated.Īssume I have bought the book ‘Last Man’ authored by Mary Shelly. You can modify my formula as per the instructions provided at the bottom of this post. Then how to generate readable IDs or product/item codes in Google Sheets using a formula(s)? Examples of Creating Unique Readable IDs in Google Docs Sheets

Here I have a formula-based approach, not an Apps Script based one, to create unique numeric/alpha-numeric item codes in Google Sheets. That was my starting point, and I'm trying to get it to work in Au3 and failing miserably.Įverything I've tried so far has produced the same results for both.Īny help you could provide me is greatly appreciated.Instead of creating lifeless unique IDs using sequential numbers, some alphabets extracted from the items and adding leading zeros, we can generate unique readable IDs in Google Sheets. In the line under the Function call, you'll see the regex I found to do this from a google search. [\p'ĬonsoleWrite(StringRegExp($sUUID, $sRegExp) & $Result = StringRegExp($sUUID, $sRegExp)ĬonsoleWrite('Error: ' & 'False'ĬonsoleWrite('Error2: ' & 'True' I am looking to create a function that will say whether or not a supplied string is a valid UUID or not. Hi all, it's been a while since I last used regular expressions and I find myself out of time to experiment with this particular issue, so I throw myself upon your mercy and expertise.
