Parsing GS1 Barcode

Parsing GS1 Barcode

Hello, I am building a simple application to capture inventory and location. The user would scan the item barcode and location barcode and would sumbit the form. I need help parsing the data. Here is a sample of an entry: 
90I-3110-991010222179550
90 identifies the Item Number, which is I-3110-99
10 identifies the Lot Number, which is 1022217
95 identifies the Location Bin, which is 50

My issue is that the Item Number and Lot Numbers can be variable in length and Identifiers digits can also be part of the Item Number, Lot Number, Location Bin. For example: first occurrence of 10 is part of the Item Number followed by a Lot Identifier and then also first 2 digits of the lot number. 

Any good methodologies on how to parse the data?

Thanks!

    Access your files securely from anywhere

        Zoho Developer Community




                                  Zoho Desk Resources

                                  • Desk Community Learning Series


                                  • Digest


                                  • Functions


                                  • Meetups


                                  • Kbase


                                  • Resources


                                  • Glossary


                                  • Desk Marketplace


                                  • MVP Corner


                                  • Word of the Day



                                      Zoho Marketing Automation


                                              Manage your brands on social media



                                                    Zoho TeamInbox Resources

                                                      Zoho DataPrep Resources



                                                        Zoho CRM Plus Resources

                                                          Zoho Books Resources


                                                            Zoho Subscriptions Resources

                                                              Zoho Projects Resources


                                                                Zoho Sprints Resources


                                                                  Qntrl Resources


                                                                    Zoho Creator Resources



                                                                        Zoho Campaigns Resources


                                                                          Zoho CRM Resources

                                                                          • CRM Community Learning Series

                                                                            CRM Community Learning Series


                                                                          • Kaizen

                                                                            Kaizen

                                                                          • Functions

                                                                            Functions

                                                                          • Meetups

                                                                            Meetups

                                                                          • Kbase

                                                                            Kbase

                                                                          • Resources

                                                                            Resources

                                                                          • Digest

                                                                            Digest

                                                                          • CRM Marketplace

                                                                            CRM Marketplace

                                                                          • MVP Corner

                                                                            MVP Corner





                                                                              Design. Discuss. Deliver.

                                                                              Create visually engaging stories with Zoho Show.

                                                                              Get Started Now