Enum num num
-
One can only wonder what was going on here....
'Generates search string using the hierarchy: '1. SEDOL and ISIN and CUSIP 2. SEDOL and ISIN 3. SEDOL 4. ISIN 5. CUSIP Public Enum HierarchycalEquitySeachType As Integer SEDOL\_ISIN\_CUSIP\_\_\_SEDOL\_ISIN\_\_\_SEDOL\_\_\_ISIN\_\_\_CUSIP End Enum
-
One can only wonder what was going on here....
'Generates search string using the hierarchy: '1. SEDOL and ISIN and CUSIP 2. SEDOL and ISIN 3. SEDOL 4. ISIN 5. CUSIP Public Enum HierarchycalEquitySeachType As Integer SEDOL\_ISIN\_CUSIP\_\_\_SEDOL\_ISIN\_\_\_SEDOL\_\_\_ISIN\_\_\_CUSIP End Enum
Don't you just love underscores? I once saw a sproc written by someone who had never heard of DATETIME as a datatype. There were about 3 million lines of "code" and, needless to say, it made vintage cat puke look pretty. The single most lamentable aspect of it, though, was that he padded his names with underscores to make everything the same length (especially ironic given that he didn't see any reason to format his code in any way whatsoever). It all went something like:
select some bilge from badlynamedappointmenttable where is_monday______morning = 0 and is_monday____afternoon = 0 and is_tuesday_____morning = 0 and is_tuesday___afternoon = 0 and is_wednesday___morning = 0 ...
Reams and reams and reams of it. How long did it take to type? How many hours did he sit there wondering why no-one had ever bothered to put some kind of date handling mechanism into an otherwise sophisticated RDBMS engine? How many times did he resist the temptation to rename his idiot columns because he couldn't figure out how many underscores to type? These, and many other questions, will probably remain unanswered for as long as the one of what on earth someone meant by ...
'Generates search string using the hierarchy:
'1. SEDOL and ISIN and CUSIP 2. SEDOL and ISIN 3. SEDOL 4. ISIN 5. CUSIP
Public Enum HierarchycalEquitySeachType As Integer
SEDOL_ISIN_CUSIP___SEDOL_ISIN___SEDOL___ISIN___CUSIP
End Enum?
98.4% of statistics are made up on the spot.
-
Don't you just love underscores? I once saw a sproc written by someone who had never heard of DATETIME as a datatype. There were about 3 million lines of "code" and, needless to say, it made vintage cat puke look pretty. The single most lamentable aspect of it, though, was that he padded his names with underscores to make everything the same length (especially ironic given that he didn't see any reason to format his code in any way whatsoever). It all went something like:
select some bilge from badlynamedappointmenttable where is_monday______morning = 0 and is_monday____afternoon = 0 and is_tuesday_____morning = 0 and is_tuesday___afternoon = 0 and is_wednesday___morning = 0 ...
Reams and reams and reams of it. How long did it take to type? How many hours did he sit there wondering why no-one had ever bothered to put some kind of date handling mechanism into an otherwise sophisticated RDBMS engine? How many times did he resist the temptation to rename his idiot columns because he couldn't figure out how many underscores to type? These, and many other questions, will probably remain unanswered for as long as the one of what on earth someone meant by ...
'Generates search string using the hierarchy:
'1. SEDOL and ISIN and CUSIP 2. SEDOL and ISIN 3. SEDOL 4. ISIN 5. CUSIP
Public Enum HierarchycalEquitySeachType As Integer
SEDOL_ISIN_CUSIP___SEDOL_ISIN___SEDOL___ISIN___CUSIP
End Enum?
98.4% of statistics are made up on the spot.
I know enumerations, but I don't know why underscores would be special in them. :confused:
Charlie Gilley <italic>Stuck in a dysfunctional matrix from which I must escape... "Where liberty dwells, there is my country." B. Franklin, 1783 “They who can give up essential liberty to obtain a little temporary safety deserve neither liberty nor safety.” BF, 1759
-
I know enumerations, but I don't know why underscores would be special in them. :confused:
Charlie Gilley <italic>Stuck in a dysfunctional matrix from which I must escape... "Where liberty dwells, there is my country." B. Franklin, 1783 “They who can give up essential liberty to obtain a little temporary safety deserve neither liberty nor safety.” BF, 1759
They aren't in any way - it seems you know enumerations better than the person who wrote that code.
-
One can only wonder what was going on here....
'Generates search string using the hierarchy: '1. SEDOL and ISIN and CUSIP 2. SEDOL and ISIN 3. SEDOL 4. ISIN 5. CUSIP Public Enum HierarchycalEquitySeachType As Integer SEDOL\_ISIN\_CUSIP\_\_\_SEDOL\_ISIN\_\_\_SEDOL\_\_\_ISIN\_\_\_CUSIP End Enum
I think we wondered about it the last time you posted that as well...[^]
What do you get when you cross a joke with a rhetorical question? The metaphorical solid rear-end expulsions have impacted the metaphorical motorized bladed rotating air movement mechanism. Do questions with multiple question marks annoy you???
-
I think we wondered about it the last time you posted that as well...[^]
What do you get when you cross a joke with a rhetorical question? The metaphorical solid rear-end expulsions have impacted the metaphorical motorized bladed rotating air movement mechanism. Do questions with multiple question marks annoy you???
Good lord - it's worse that I thought! (I should have fixed it back then....)
-
They aren't in any way - it seems you know enumerations better than the person who wrote that code.
They are if you get the enum element name using ToString, and then Split it:
Dim h As HierarchycalEquitySeachType = HierarchycalEquitySeachType.SEDOL_ISIN_CUSIP___SEDOL_ISIN___SEDOL___ISIN___CUSIP
Dim HierarchycalEquitySeachType____Value As String = h.ToString()
Dim searchHierarchy As String() = HierarchycalEquitySeachType____Value.Split(New Char() {"_"C}, StringSplitOptions.RemoveEmptyEntries)yOu then have the hierarchy you need. Probably.
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay... AntiTwitter: @DalekDave is now a follower!
-
They are if you get the enum element name using ToString, and then Split it:
Dim h As HierarchycalEquitySeachType = HierarchycalEquitySeachType.SEDOL_ISIN_CUSIP___SEDOL_ISIN___SEDOL___ISIN___CUSIP
Dim HierarchycalEquitySeachType____Value As String = h.ToString()
Dim searchHierarchy As String() = HierarchycalEquitySeachType____Value.Split(New Char() {"_"C}, StringSplitOptions.RemoveEmptyEntries)yOu then have the hierarchy you need. Probably.
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay... AntiTwitter: @DalekDave is now a follower!
Likely only partially correct. Looking at the comment above the enum definition and at its single member, I conclude that the first split to be done uses 3 underscores, afterwards each item gets split with a single underscore.
Oh sanctissimi Wilhelmus, Theodorus, et Fredericus!
-
Likely only partially correct. Looking at the comment above the enum definition and at its single member, I conclude that the first split to be done uses 3 underscores, afterwards each item gets split with a single underscore.
Oh sanctissimi Wilhelmus, Theodorus, et Fredericus!
No, the extra underscores are there for emphasis!
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay... AntiTwitter: @DalekDave is now a follower!