Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. It's Not A Number

It's Not A Number

Scheduled Pinned Locked Moved The Lounge
javascriptcloudhelpcsharplinq
21 Posts 14 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Sander RosselS Offline
    Sander RosselS Offline
    Sander Rossel
    wrote on last edited by
    #1

    So I'm writing a system that deals with so-called UBNs (Unique Bedrijfs/Company Numbers). The value is 7 characters long for Dutch companies in the branch I'm working for. However... Some aren't, so you get a leading 0, like 0123456. Now, I have an import, which does not give me the leading 0. As a result my customer omitted the leading 0 from their master data as well. However, we have a service that customers connect to, which does use the leading 0. So, made a fix for the import and forced this UBN to be at least 7 characters, problem solved... Except that I just found out some third party software does not include a leading 0 when accessing our service (even though it's set in the settings!) X| Event their logs show the leading 0, but my logs say differently. Who the hell comes up with this shit? :((

    Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

    Greg UtasG 5 S D O 10 Replies Last reply
    0
    • Sander RosselS Sander Rossel

      So I'm writing a system that deals with so-called UBNs (Unique Bedrijfs/Company Numbers). The value is 7 characters long for Dutch companies in the branch I'm working for. However... Some aren't, so you get a leading 0, like 0123456. Now, I have an import, which does not give me the leading 0. As a result my customer omitted the leading 0 from their master data as well. However, we have a service that customers connect to, which does use the leading 0. So, made a fix for the import and forced this UBN to be at least 7 characters, problem solved... Except that I just found out some third party software does not include a leading 0 when accessing our service (even though it's set in the settings!) X| Event their logs show the leading 0, but my logs say differently. Who the hell comes up with this shit? :((

      Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

      Greg UtasG Offline
      Greg UtasG Offline
      Greg Utas
      wrote on last edited by
      #2

      It's a number that all companies have, so I think I know whence it came. :laugh: It's also unsurprising that different systems treat it differently, causing interworking problems. The joy of software. And :rose: too, but I couldn't help but find this amusing!

      Robust Services Core | Software Techniques for Lemmings | Articles
      The fox knows many things, but the hedgehog knows one big thing.

      <p><a href="https://github.com/GregUtas/robust-services-core/blob/master/README.md">Robust Services Core</a>
      <em>The fox knows many things, but the hedgehog knows one big thing.</em></p>

      Sander RosselS 1 Reply Last reply
      0
      • Sander RosselS Sander Rossel

        So I'm writing a system that deals with so-called UBNs (Unique Bedrijfs/Company Numbers). The value is 7 characters long for Dutch companies in the branch I'm working for. However... Some aren't, so you get a leading 0, like 0123456. Now, I have an import, which does not give me the leading 0. As a result my customer omitted the leading 0 from their master data as well. However, we have a service that customers connect to, which does use the leading 0. So, made a fix for the import and forced this UBN to be at least 7 characters, problem solved... Except that I just found out some third party software does not include a leading 0 when accessing our service (even though it's set in the settings!) X| Event their logs show the leading 0, but my logs say differently. Who the hell comes up with this shit? :((

        Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

        5 Offline
        5 Offline
        5teveH
        wrote on last edited by
        #3

        Sander Rossel wrote:

        Who the hell comes up with this sh*t?

        They 'all' do. And the sooner 'they' can be replaced with AI, the better. Because right now we only get genuine stupidity! :doh:

        C 1 Reply Last reply
        0
        • 5 5teveH

          Sander Rossel wrote:

          Who the hell comes up with this sh*t?

          They 'all' do. And the sooner 'they' can be replaced with AI, the better. Because right now we only get genuine stupidity! :doh:

          C Offline
          C Offline
          CodeWraith
          wrote on last edited by
          #4

          Optimist. With our luck we only get AS, not AI.

          I have lived with several Zen masters - all of them were cats. His last invention was an evil Lasagna. It didn't kill anyone, and it actually tasted pretty good.

          M 1 Reply Last reply
          0
          • Greg UtasG Greg Utas

            It's a number that all companies have, so I think I know whence it came. :laugh: It's also unsurprising that different systems treat it differently, causing interworking problems. The joy of software. And :rose: too, but I couldn't help but find this amusing!

            Robust Services Core | Software Techniques for Lemmings | Articles
            The fox knows many things, but the hedgehog knows one big thing.

            Sander RosselS Offline
            Sander RosselS Offline
            Sander Rossel
            wrote on last edited by
            #5

            Greg Utas wrote:

            but I couldn't help but find this amusing!

            It would be if it didn't happen to me :laugh: Leading zeroes always make me nervous, this isn't the first time I've run into this problem :rolleyes:

            Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

            1 Reply Last reply
            0
            • Sander RosselS Sander Rossel

              So I'm writing a system that deals with so-called UBNs (Unique Bedrijfs/Company Numbers). The value is 7 characters long for Dutch companies in the branch I'm working for. However... Some aren't, so you get a leading 0, like 0123456. Now, I have an import, which does not give me the leading 0. As a result my customer omitted the leading 0 from their master data as well. However, we have a service that customers connect to, which does use the leading 0. So, made a fix for the import and forced this UBN to be at least 7 characters, problem solved... Except that I just found out some third party software does not include a leading 0 when accessing our service (even though it's set in the settings!) X| Event their logs show the leading 0, but my logs say differently. Who the hell comes up with this shit? :((

              Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

              S Offline
              S Offline
              Slacker007
              wrote on last edited by
              #6

              Sander Rossel wrote:

              Who the hell comes up with this sh*t?

              Ah, a question for the ages. :laugh:

              1 Reply Last reply
              0
              • Sander RosselS Sander Rossel

                So I'm writing a system that deals with so-called UBNs (Unique Bedrijfs/Company Numbers). The value is 7 characters long for Dutch companies in the branch I'm working for. However... Some aren't, so you get a leading 0, like 0123456. Now, I have an import, which does not give me the leading 0. As a result my customer omitted the leading 0 from their master data as well. However, we have a service that customers connect to, which does use the leading 0. So, made a fix for the import and forced this UBN to be at least 7 characters, problem solved... Except that I just found out some third party software does not include a leading 0 when accessing our service (even though it's set in the settings!) X| Event their logs show the leading 0, but my logs say differently. Who the hell comes up with this shit? :((

                Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                D Offline
                D Offline
                Daniel Pfeffer
                wrote on last edited by
                #7

                The same thing happens with Israeli ID numbers. Numbers issued in the last 40-odd years have 9 digits, of which the first encodes the type (company, person born in Israel, person born abroad, etc.), 7 are the ID, and the last is a checksum digit. The first digit is never a zero. The older 7-digit ID numbers were expanded to 9 digits by padding the number on the left with zeros, and adding the checksum digit. For some old-timers, this leads to an interesting ID number such as 000012345.

                Freedom is the freedom to say that two plus two make four. If that is granted, all else follows. -- 6079 Smith W.

                K 1 Reply Last reply
                0
                • D Daniel Pfeffer

                  The same thing happens with Israeli ID numbers. Numbers issued in the last 40-odd years have 9 digits, of which the first encodes the type (company, person born in Israel, person born abroad, etc.), 7 are the ID, and the last is a checksum digit. The first digit is never a zero. The older 7-digit ID numbers were expanded to 9 digits by padding the number on the left with zeros, and adding the checksum digit. For some old-timers, this leads to an interesting ID number such as 000012345.

                  Freedom is the freedom to say that two plus two make four. If that is granted, all else follows. -- 6079 Smith W.

                  K Offline
                  K Offline
                  Keith Barrow
                  wrote on last edited by
                  #8

                  Daniel Pfeffer wrote:

                  For some old-timers, this leads to an interesting ID number such as 000012345.

                  Literally nothing better than being a walking test case with an ID like that

                  KeithBarrow.net[^] - It might not be very good, but at least it is free!

                  1 Reply Last reply
                  0
                  • Sander RosselS Sander Rossel

                    So I'm writing a system that deals with so-called UBNs (Unique Bedrijfs/Company Numbers). The value is 7 characters long for Dutch companies in the branch I'm working for. However... Some aren't, so you get a leading 0, like 0123456. Now, I have an import, which does not give me the leading 0. As a result my customer omitted the leading 0 from their master data as well. However, we have a service that customers connect to, which does use the leading 0. So, made a fix for the import and forced this UBN to be at least 7 characters, problem solved... Except that I just found out some third party software does not include a leading 0 when accessing our service (even though it's set in the settings!) X| Event their logs show the leading 0, but my logs say differently. Who the hell comes up with this shit? :((

                    Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                    O Offline
                    O Offline
                    obermd
                    wrote on last edited by
                    #9

                    If I expect a leading zero in a number I always plan on padding them on.

                    1 Reply Last reply
                    0
                    • Sander RosselS Sander Rossel

                      So I'm writing a system that deals with so-called UBNs (Unique Bedrijfs/Company Numbers). The value is 7 characters long for Dutch companies in the branch I'm working for. However... Some aren't, so you get a leading 0, like 0123456. Now, I have an import, which does not give me the leading 0. As a result my customer omitted the leading 0 from their master data as well. However, we have a service that customers connect to, which does use the leading 0. So, made a fix for the import and forced this UBN to be at least 7 characters, problem solved... Except that I just found out some third party software does not include a leading 0 when accessing our service (even though it's set in the settings!) X| Event their logs show the leading 0, but my logs say differently. Who the hell comes up with this shit? :((

                      Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                      P Offline
                      P Offline
                      PIEBALDconsult
                      wrote on last edited by
                      #10

                      About ten years ago I had to interface with a third-party system via sockets. The specification for the socket API specified that each message had to be identified by a ten-digit ID -- any ten digits would do, it just had to be unique. I decided to use the first two digits to identify (to myself) what type of message it was. For most messages I used "00", but for some special messages (like when querying the health of the other system) I used "99" or "98". BOOM! The response was always that the message was invalid and the system was resetting. I contacted the developer at the vendor (the guru who developed and documented the API) and he said that my messages should have been valid and he had no idea why the system was behaving as I had described it to him. A few days later he told me the reason -- the developers of the application hadn't understood the API specification and had assumed that the ID was a 32-bit integer (!) and they were trying to parse the ten digits :sigh: . Once he got them straightened out they fixed their code and all was good after we installed an update. Whether the fix was to use a string or a 64-bit integer on their side I will never know.

                      Sander RosselS 1 Reply Last reply
                      0
                      • P PIEBALDconsult

                        About ten years ago I had to interface with a third-party system via sockets. The specification for the socket API specified that each message had to be identified by a ten-digit ID -- any ten digits would do, it just had to be unique. I decided to use the first two digits to identify (to myself) what type of message it was. For most messages I used "00", but for some special messages (like when querying the health of the other system) I used "99" or "98". BOOM! The response was always that the message was invalid and the system was resetting. I contacted the developer at the vendor (the guru who developed and documented the API) and he said that my messages should have been valid and he had no idea why the system was behaving as I had described it to him. A few days later he told me the reason -- the developers of the application hadn't understood the API specification and had assumed that the ID was a 32-bit integer (!) and they were trying to parse the ten digits :sigh: . Once he got them straightened out they fixed their code and all was good after we installed an update. Whether the fix was to use a string or a 64-bit integer on their side I will never know.

                        Sander RosselS Offline
                        Sander RosselS Offline
                        Sander Rossel
                        wrote on last edited by
                        #11

                        Been there, done that :laugh: The "standard" I'm currently using defines fields and values in a message. I've had to exchange messages with two parties so far, and both had their own "interpretation" of which fields were mandatory. For the SOAP definition I had to create a completely different version :sigh: The latest version of the spec, which is actually a pretty detailed document, is about 15 years old, so that shouldn't be the problem :laugh:

                        Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                        1 Reply Last reply
                        0
                        • Sander RosselS Sander Rossel

                          So I'm writing a system that deals with so-called UBNs (Unique Bedrijfs/Company Numbers). The value is 7 characters long for Dutch companies in the branch I'm working for. However... Some aren't, so you get a leading 0, like 0123456. Now, I have an import, which does not give me the leading 0. As a result my customer omitted the leading 0 from their master data as well. However, we have a service that customers connect to, which does use the leading 0. So, made a fix for the import and forced this UBN to be at least 7 characters, problem solved... Except that I just found out some third party software does not include a leading 0 when accessing our service (even though it's set in the settings!) X| Event their logs show the leading 0, but my logs say differently. Who the hell comes up with this shit? :((

                          Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                          M Offline
                          M Offline
                          Mycroft Holmes
                          wrote on last edited by
                          #12

                          Ah stop your bitching, I worked with a financial system where the traders were allowed to enter 1.23m or 1.23 mil or basically anything they liked for numerical values. Try doing financial regulatory reports on such shite that had to be accurate to the cent.

                          Never underestimate the power of human stupidity - RAH I'm old. I know stuff - JSOP

                          Sander RosselS 1 Reply Last reply
                          0
                          • Sander RosselS Sander Rossel

                            So I'm writing a system that deals with so-called UBNs (Unique Bedrijfs/Company Numbers). The value is 7 characters long for Dutch companies in the branch I'm working for. However... Some aren't, so you get a leading 0, like 0123456. Now, I have an import, which does not give me the leading 0. As a result my customer omitted the leading 0 from their master data as well. However, we have a service that customers connect to, which does use the leading 0. So, made a fix for the import and forced this UBN to be at least 7 characters, problem solved... Except that I just found out some third party software does not include a leading 0 when accessing our service (even though it's set in the settings!) X| Event their logs show the leading 0, but my logs say differently. Who the hell comes up with this shit? :((

                            Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                            E Offline
                            E Offline
                            englebart
                            wrote on last edited by
                            #13

                            1. Excel messes up leading 0s 2. Octal nightmare 3. Blame it on EBCDIC, space comes after 9 in ordinal order! I think I learned these from a David Letterman top ten list, but I forgot the other 7.

                            Sander RosselS 1 Reply Last reply
                            0
                            • E englebart

                              1. Excel messes up leading 0s 2. Octal nightmare 3. Blame it on EBCDIC, space comes after 9 in ordinal order! I think I learned these from a David Letterman top ten list, but I forgot the other 7.

                              Sander RosselS Offline
                              Sander RosselS Offline
                              Sander Rossel
                              wrote on last edited by
                              #14

                              englebart wrote:

                              Excel messes up leading 0s

                              And more! I get a CSV file from a customer, but they often edit it using Excel. There go the leading zeroes, decimals, date formats... X|

                              Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                              1 Reply Last reply
                              0
                              • M Mycroft Holmes

                                Ah stop your bitching, I worked with a financial system where the traders were allowed to enter 1.23m or 1.23 mil or basically anything they liked for numerical values. Try doing financial regulatory reports on such shite that had to be accurate to the cent.

                                Never underestimate the power of human stupidity - RAH I'm old. I know stuff - JSOP

                                Sander RosselS Offline
                                Sander RosselS Offline
                                Sander Rossel
                                wrote on last edited by
                                #15

                                Mycroft Holmes wrote:

                                or basically anything they liked for except numerical values.

                                FTFY :laugh: Why would you even want that? :wtf:

                                Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                                M 1 Reply Last reply
                                0
                                • Sander RosselS Sander Rossel

                                  So I'm writing a system that deals with so-called UBNs (Unique Bedrijfs/Company Numbers). The value is 7 characters long for Dutch companies in the branch I'm working for. However... Some aren't, so you get a leading 0, like 0123456. Now, I have an import, which does not give me the leading 0. As a result my customer omitted the leading 0 from their master data as well. However, we have a service that customers connect to, which does use the leading 0. So, made a fix for the import and forced this UBN to be at least 7 characters, problem solved... Except that I just found out some third party software does not include a leading 0 when accessing our service (even though it's set in the settings!) X| Event their logs show the leading 0, but my logs say differently. Who the hell comes up with this shit? :((

                                  Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                                  L Offline
                                  L Offline
                                  Leo56
                                  wrote on last edited by
                                  #16

                                  Well, in my case it was an Admin Manager who passed out a 'file format' to 40 or so customers for a CSV return with (30+) columns described as 'Number', 'Text' and 'Date'.... :sigh:

                                  Sander RosselS 1 Reply Last reply
                                  0
                                  • Sander RosselS Sander Rossel

                                    So I'm writing a system that deals with so-called UBNs (Unique Bedrijfs/Company Numbers). The value is 7 characters long for Dutch companies in the branch I'm working for. However... Some aren't, so you get a leading 0, like 0123456. Now, I have an import, which does not give me the leading 0. As a result my customer omitted the leading 0 from their master data as well. However, we have a service that customers connect to, which does use the leading 0. So, made a fix for the import and forced this UBN to be at least 7 characters, problem solved... Except that I just found out some third party software does not include a leading 0 when accessing our service (even though it's set in the settings!) X| Event their logs show the leading 0, but my logs say differently. Who the hell comes up with this shit? :((

                                    Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                                    B Offline
                                    B Offline
                                    Bruce Patin
                                    wrote on last edited by
                                    #17

                                    I never, ever start a numerical sequence with leading zeros. Never. Add a 1 at the beginning.

                                    Sander RosselS 1 Reply Last reply
                                    0
                                    • B Bruce Patin

                                      I never, ever start a numerical sequence with leading zeros. Never. Add a 1 at the beginning.

                                      Sander RosselS Offline
                                      Sander RosselS Offline
                                      Sander Rossel
                                      wrote on last edited by
                                      #18

                                      To be clear, it's not my number. It's some government issued number :sigh:

                                      Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                                      1 Reply Last reply
                                      0
                                      • L Leo56

                                        Well, in my case it was an Admin Manager who passed out a 'file format' to 40 or so customers for a CSV return with (30+) columns described as 'Number', 'Text' and 'Date'.... :sigh:

                                        Sander RosselS Offline
                                        Sander RosselS Offline
                                        Sander Rossel
                                        wrote on last edited by
                                        #19

                                        He should add "Decimal" just to be 100% clear :laugh:

                                        Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                                        1 Reply Last reply
                                        0
                                        • Sander RosselS Sander Rossel

                                          Mycroft Holmes wrote:

                                          or basically anything they liked for except numerical values.

                                          FTFY :laugh: Why would you even want that? :wtf:

                                          Best, Sander Azure DevOps Succinctly (free eBook) Azure Serverless Succinctly (free eBook) Migrating Apps to the Cloud with Azure arrgh.js - Bringing LINQ to JavaScript

                                          M Offline
                                          M Offline
                                          Mycroft Holmes
                                          wrote on last edited by
                                          #20

                                          Trading platform and guess who made the bank the most money, so traders (lazy, ignorant, opinionated arseholes) get to dictate what they want.

                                          Never underestimate the power of human stupidity - RAH I'm old. I know stuff - JSOP

                                          1 Reply Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • World
                                          • Users
                                          • Groups