Click here to Skip to main content
15,868,440 members

The Weird and The Wonderful

   

The Weird and The Wonderful forum is a place to post Coding Horrors, Worst Practices, and the occasional flash of brilliance.

We all come across code that simply boggles the mind. Lazy kludges, embarrassing mistakes, horrid workarounds and developers just not quite getting it. And then somedays we come across - or write - the truly sublime.

Post your Best, your worst, and your most interesting. But please - no programming questions . This forum is purely for amusement and discussions on code snippets. All actual programming questions will be removed.

 
GeneralRe: .NET is Hell (subtitle: An error message from Microsoft) Pin
Stefan_Lang15-Oct-12 4:53
Stefan_Lang15-Oct-12 4:53 
GeneralInfinate levels of hierarchal data Pin
asdrog3-Oct-12 1:30
asdrog3-Oct-12 1:30 
GeneralRe: MySQL "in (list)" example to recursivly get information - And the power of Loops! Infinate levels of hierarchal data Pin
R. Giskard Reventlov3-Oct-12 5:22
R. Giskard Reventlov3-Oct-12 5:22 
GeneralRe: MySQL "in (list)" example to recursivly get information - And the power of Loops! Infinate levels of hierarchal data Pin
asdrog3-Oct-12 6:30
asdrog3-Oct-12 6:30 
GeneralRe: MySQL "in (list)" example to recursivly get information - And the power of Loops! Infinate levels of hierarchal data Pin
R. Giskard Reventlov3-Oct-12 6:43
R. Giskard Reventlov3-Oct-12 6:43 
GeneralRe: MySQL "in (list)" example to recursivly get information - And the power of Loops! Infinate levels of hierarchal data Pin
AspDotNetDev3-Oct-12 6:45
protectorAspDotNetDev3-Oct-12 6:45 
GeneralRe: MySQL "in (list)" example to recursivly get information - And the power of Loops! Infinate levels of hierarchal data Pin
R. Giskard Reventlov3-Oct-12 7:02
R. Giskard Reventlov3-Oct-12 7:02 
GeneralRe: MySQL "in (list)" example to recursivly get information - And the power of Loops! Infinate levels of hierarchal data Pin
asdrog3-Oct-12 13:21
asdrog3-Oct-12 13:21 
The illustrated structure is not the normal approach to db design and not tought to everyone, It wasn't in my day. But is now given in some hard back publications, for the intermediate skilled person, as an example of how to use a database to run the .net menu control.

Some folk prefer to code XML files to run the .net menu controls, but others prefer a database. Thus allowing one to standardise on using datbases for everything rather than a mix of db and xml on a website.Thumbs Up | :thumbsup:

The structure is also great for managing lists as one does not need one table for the list name and one for the list items, less overheadThumbs Up | :thumbsup:
For example it is great for the storage of dropdown list values as one can basically use the same sql for all dropdown controls - just passing a different 'ParentID' to get a different data set for the control.
This simplifies life in some areas when buildiong a N-Tier Application -
Select field1, field2 From table Where ParentID = @ParentID
is all you would ever need to code against/use to retrieve any list!Thumbs Up | :thumbsup:

It all boils down to preference, what you need to do and how you have been tought!
The structure is not for everyone and everyone should always use what they are happiest using.
Happy coding Smile | :)
GeneralRe: MySQL "in (list)" example to recursivly get information - And the power of Loops! Infinate levels of hierarchal data Pin
Sentenryu4-Oct-12 0:50
Sentenryu4-Oct-12 0:50 
GeneralRe: Infinate levels of hierarchal data Pin
Bernhard Hiller4-Oct-12 0:28
Bernhard Hiller4-Oct-12 0:28 
GeneralRe: Infinate levels of hierarchal data Pin
asdrog4-Oct-12 11:35
asdrog4-Oct-12 11:35 
GeneralRe: Infinate levels of hierarchal data Pin
AspDotNetDev4-Oct-12 12:24
protectorAspDotNetDev4-Oct-12 12:24 
GeneralRe: Infinate levels of hierarchal data Pin
asdrog4-Oct-12 13:20
asdrog4-Oct-12 13:20 
GeneralCSS selector of the day Pin
Chris Maunder2-Oct-12 8:41
cofounderChris Maunder2-Oct-12 8:41 
GeneralRe: CSS selector of the day Pin
Brisingr Aerowing2-Oct-12 9:32
professionalBrisingr Aerowing2-Oct-12 9:32 
GeneralRe: CSS selector of the day Pin
Mike Ortmans2-Oct-12 22:38
Mike Ortmans2-Oct-12 22:38 
GeneralRe: CSS selector of the day Pin
BobJanova2-Oct-12 23:31
BobJanova2-Oct-12 23:31 
GeneralRe: CSS selector of the day Pin
Chris Maunder3-Oct-12 4:19
cofounderChris Maunder3-Oct-12 4:19 
JokeRe: CSS selector of the day Pin
fjdiewornncalwe3-Oct-12 4:23
professionalfjdiewornncalwe3-Oct-12 4:23 
GeneralRe: CSS selector of the day Pin
Sentenryu3-Oct-12 1:11
Sentenryu3-Oct-12 1:11 
GeneralRe: CSS selector of the day Pin
Yvan Rodrigues3-Oct-12 3:55
professionalYvan Rodrigues3-Oct-12 3:55 
GeneralRe: CSS selector of the day Pin
jayson lorenzen3-Oct-12 5:03
jayson lorenzen3-Oct-12 5:03 
GeneralRe: CSS selector of the day Pin
César de Souza3-Oct-12 5:13
professionalCésar de Souza3-Oct-12 5:13 
GeneralRe: CSS selector of the day Pin
Chris Maunder3-Oct-12 8:20
cofounderChris Maunder3-Oct-12 8:20 
GeneralRe: CSS selector of the day Pin
jsc4211-Oct-12 0:43
professionaljsc4211-Oct-12 0:43 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.