Click here to Skip to main content
15,434,078 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: Evolution of a stored proc Pin
Mike Winiberg16-Jul-12 20:14
professionalMike Winiberg16-Jul-12 20:14 
GeneralRe: Evolution of a stored proc Pin
AspDotNetDev16-Jul-12 20:45
protectorAspDotNetDev16-Jul-12 20:45 
GeneralRe: Evolution of a stored proc Pin
greldak16-Jul-12 21:43
Membergreldak16-Jul-12 21:43 
GeneralRe: Evolution of a stored proc Pin
Stefan_Lang16-Jul-12 21:55
mveStefan_Lang16-Jul-12 21:55 
GeneralRe: Evolution of a stored proc Pin
yiangos16-Jul-12 22:43
professionalyiangos16-Jul-12 22:43 
GeneralRe: Evolution of a stored proc Pin
Jan Holst Jensen217-Jul-12 1:01
MemberJan Holst Jensen217-Jul-12 1:01 
GeneralRe: Evolution of a stored proc Pin
yiangos17-Jul-12 9:16
professionalyiangos17-Jul-12 9:16 
GeneralRe: Evolution of a stored proc Pin
Florin Jurcovici17-Jul-12 1:31
MemberFlorin Jurcovici17-Jul-12 1:31 
You can refactor it. Also, I don't know for Oracle or other DBs, but there's a debugger with breakpoints, local vars, step into and all such stuff available for MySQL.

OTOH, packing business logic into SQL (which I'm under the impression that it happens here) is always a bad idea - unless you really do pack your entire logic in SQL, and have stored procedures which are in fact the equivalent of services, and no or almost no logic in your client app.

And yes, I do agree it's horrible the way it is now. Whoever designed the database clearly has no notion of sane naming conventions.
GeneralRe: Evolution of a stored proc Pin
Harley L. Pebley17-Jul-12 4:47
MemberHarley L. Pebley17-Jul-12 4:47 
GeneralRe: Evolution of a stored proc Pin
krumia17-Jul-12 20:20
Memberkrumia17-Jul-12 20:20 
GeneralWhen to check for null ? Pin
Sasha Laurel10-Jul-12 6:19
MemberSasha Laurel10-Jul-12 6:19 
GeneralRe: When to check for null ? Pin
Brisingr Aerowing10-Jul-12 13:55
professionalBrisingr Aerowing10-Jul-12 13:55 
GeneralRe: When to check for null ? Pin
Sasha Laurel10-Jul-12 18:59
MemberSasha Laurel10-Jul-12 18:59 
GeneralRe: When to check for null ? Pin
Brisingr Aerowing11-Jul-12 4:37
professionalBrisingr Aerowing11-Jul-12 4:37 
GeneralRe: When to check for null ? Pin
CDP180210-Jul-12 22:25
MemberCDP180210-Jul-12 22:25 
GeneralRe: When to check for null ? Pin
Julien Villers10-Jul-12 23:24
professionalJulien Villers10-Jul-12 23:24 
GeneralRe: When to check for null ? Pin
CDP180211-Jul-12 0:26
MemberCDP180211-Jul-12 0:26 
GeneralRe: When to check for null ? Pin
Julien Villers11-Jul-12 0:47
professionalJulien Villers11-Jul-12 0:47 
GeneralRe: When to check for null ? Pin
Sasha Laurel11-Jul-12 4:52
MemberSasha Laurel11-Jul-12 4:52 
GeneralRe: When to check for null ? Pin
CDP180212-Jul-12 1:28
MemberCDP180212-Jul-12 1:28 
GeneralRe: When to check for null ? Pin
Sasha Laurel12-Jul-12 4:55
MemberSasha Laurel12-Jul-12 4:55 
GeneralRe: When to check for null ? Pin
CDP180212-Jul-12 14:26
MemberCDP180212-Jul-12 14:26 
JokeRe: When to check for null ? Pin
Sasha Laurel12-Jul-12 16:10
MemberSasha Laurel12-Jul-12 16:10 
GeneralRe: When to check for null ? Pin
CDP180212-Jul-12 23:18
MemberCDP180212-Jul-12 23:18 
GeneralRe: When to check for null ? Pin
Andrei Straut11-Jul-12 5:04
MemberAndrei Straut11-Jul-12 5:04 

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.