• cowbert (unregistered) in reply to kdd
    kdd:

    Reminds me of a large IT consulting company that implements their 'resuable software framework' in client projects.

    It uses all the latest technologies. It's kind of a write once and no more code changes approach.

    Every attribute of each component in the entire Web UI is stored in a database.(font, x, y, size, page, etc.). Plus workflow, navigation, page layouts, security, etc. also in the same database.

    Want to change that label text in a page -- easy!! Change the value in column x in table y to 'z'.

    Want to add a new button -- add a new row to couple tables!

    See - Nothing is hardcoded. No recompilation. No deployment.

    As Staples says 'That was easy!'

    Don't need any more programmers after the first implementation.

    May also know as the Crazy Extreme programming.

    Yep! the learning curve is a lot of fun.



    This is probably good for a small company that entirely outsources its customer facing IT (or an academic environment). I'm building something like this using templates that are edited using forms so that the PHBs/faculty who will be "maintaining" the site after the development contract ends can do so without having to look at any code. The db has an overlying metdata framework so that new tables, fields, and relationships can be defined without having to use SQL (like a poor man's Access linked to Crystal). Reminds me of the "web page wizard" that Geocities used to have in the 1990s for people who didn't know (and couldn't/wouldn't learn) HTML.
  • Nicolai A. Kollner (unregistered)

    Woo hooo... My submission is a daily wtf classic [:D]

  • (cs) in reply to DZ-Jay
    DZ-Jay:
    mizhi:
    Anonymous:

    <FONT face=Arial>Dude...</FONT>

    <FONT face=Arial>This was already posted.  WTF???</FONT>



    There seems to be a disconcerting number of people on this forum that lack basic reading comprehension skills.


    There seems to be a disconcerting number of people on this forum that lack a basic sense of humour.

        dZ.

    Yeah. I guess it was funny the first 50 times, should be just as funny the next 1000.

     

  • zorro (unregistered) in reply to diaphanein
    Anonymous:

    I love how people mock that which they do not understand.  There is a very simple reason for doing this.  Performance.

    You're joking? Performance? If you want performance get your schema right, get your queries tuned like crazy (his query doesn't look like the fastest guy in town so that alone is killing the performance argument). This is where you'll save a lot of time. Then use caching a lot if it's still slow, and to generate the html just use a basic programming laguage that's fast with strings (perl, or even C if you feel like hurting yourself); but don't do that piece of WTF sqlHTML.
  • (cs) in reply to diaphanein
    Anonymous:

    emptyset:
    <FONT face="Courier New" size=2>certain substrings in variable names are classic indicators of Great Programming Skill (tm).  "blob" certainly falls into this category.</FONT>

    "blob" is actually a datatype in some DBMSes.  So is "CLOB" and "GLOB". These are large objects.  FileBlob actually makes a fair amount of sense.

    I love how people mock that which they do not understand.  There is a very simple reason for doing this.  Performance.  Yes, its harder to maintain, yes it abuses the database, but it can be significantly faster.  In old data-driven ASP pages, I used this technique a fair amount.  Not nearly to this degree, but I used it.  To save iterating in an interepretted language on my slow ASP host (I'm talking a dual 200 Mhz Pentium Pro), I used my mainframe DBMS host to generate some of my html.

    Response time to client before:  30s.  Response time after the change:  <1s.

    You're joking? Performance? If you want performance get your schema right, get your queries tuned like crazy (his query doesn't look like the fastest guy in town so that alone is killing the performance argument). This is where you'll save a lot of time. Then use caching a lot if it's still slow, and to generate the html just use a basic programming laguage that's fast with strings (perl, or even C if you feel like hurting yourself); but don't do that piece of WTF sqlHTML.

    (sorry for the double post, the previous message's html was bad).

  • (cs) in reply to zorro

    sorry for the html horror above, apparently safari on os x is not the tool of choice for this site (quire ironic wtf in itself).

  • (cs) in reply to zorro
    zorro:
    sorry for the html horror above, apparently safari on os x is not the tool of choice for this site (quire ironic wtf in itself).

    It's okay, DailyWTF hates equally on all browsers. The stars and planets have to be aligned just right for quotes to work.
  • (cs) in reply to foxyshadis

    foxyshadis:
    zorro:
    sorry for the html horror above, apparently safari on os x is not the tool of choice for this site (quire ironic wtf in itself).

    It's okay, DailyWTF hates equally on all browsers. The stars and planets have to be aligned just right for quotes to work.

    LOL Just whatever you do, play it safe and don't preview or go into HTML mode.

    Type what you need, and hit Post. Although maybe I've just been lucky so far - I haven't even tried the emoticons or fonts yet...

     

  • (cs) in reply to diaphanein
    Anonymous:

    I love how people mock that which they do not understand.  There is a very simple reason for doing this.  Performance.  Yes, its harder to maintain, yes it abuses the database, but it can be significantly faster.  In old data-driven ASP pages, I used this technique a fair amount.  Not nearly to this degree, but I used it.  To save iterating in an interepretted language on my slow ASP host (I'm talking a dual 200 Mhz Pentium Pro), I used my mainframe DBMS host to generate some of my html.

    Response time to client before:  30s.  Response time after the change:  <1s.



    <font size="2">so, by intentionally using the wrong tool(s), you create a maintenance nightmare?</font>
  • Bob (unregistered) in reply to Ytram

    Ytram:
    Kippesoep:
    Hmmm... that's a cool technique. I may want to redesign my content management system. Maybe I can put the stylesheets into the stored procedures, too!


    Why stop there??  You can have javascript stored in the database, and you can also store all of your images as blobs in the database.

    Btw, to the OP, this has been posted before.  You might want to use the search function before posting.

    Why not even store the webserver in the DB while you're at it... keep it all in the same place.

    On a side note: Using my keen powers of reading... I can see that you may have missed the point [:)]. These are 'classic WTF' posts... i.e. ones which have been posted before. So, to semi-quote yourself... You may want to read the OP before replying [:D].

  • (cs) in reply to foxyshadis
    foxyshadis:
    zorro:
    sorry for the html horror above, apparently safari on os x is not the tool of choice for this site (quire ironic wtf in itself).

    It's okay, DailyWTF hates equally on all browsers. The stars and planets have to be aligned just right for quotes to work.


    Just stay away from Preview and all will be fine.




    I eagerly await the system that will allow me to use all web-languages in a single file. I'm assuming this would start with the SP's, from where I can write ASP, which writes the XHTML, JS and CSS, or the XML and XSLT, depending on your Xual orientation.
  • Toby (UK) (unregistered) in reply to dhromed

    Reminds me of a classic dilbert

    PHB:I think we should build an SQL database
    DILBERT:
    DILBERT:What colour do you want that database
    PHB:I think mauve has the most RAM ....

  • Toby (UK) (unregistered) in reply to Toby (UK)

    <sigh> sorry about that, I really don't like this forum software much (even though the forum itself is great :) )

    it should have read ....

    Reminds me of a classic dilbert

    PHB:I think we should build an SQL database
    DILBERT:<thinks:Does he understand what he said or is it something he saw in a trade magazine ad?>
    DILBERT:What colour do you want that database
    PHB:I think mauve has the most RAM ....

  • (cs) in reply to DZ-Jay
    Anonymous:
    DZ-Jay:

    There seems to be a disconcerting number of people on this forum that lack basic reading comprehension skills.

    what


    Hum... You quoted me wrong.  That comment does not belong to me.  Below is the actual comment:


    DZ-Jay:
    mizhi:
    Anonymous:

    <font face="Arial">Dude...</font>

    <font face="Arial">This was already posted.  WTF???</font>



    There seems to be a disconcerting number of people on this forum that lack basic reading comprehension skills.


    There seems to be a disconcerting number of people on this forum that lack a basic sense of humour.

        dZ.

  • Hank Miller (unregistered) in reply to dhromed
    dhromed:

    I eagerly await the system that will allow me to use all web-languages in a single file. I'm assuming this would start with the SP's, from where I can write ASP, which writes the XHTML, JS and CSS, or the XML and XSLT, depending on your Xual orientation.


    It doesn't do web languages, but SWIG lets you mix C, C++, perl, python, ruby, scheme, and a dozen other languages in the same file (including php, so I suppose you could mix XHTML, JS, CSS, and XML if you really tried).    Trust me, just C++ and python mixed in the same file looks like a WTF, I'd hate to see someone actually try to mix everything SWIG can do in one file.   (Swig gives some provision for serarating the languages, but it is a little more complex than necessary for just two)


  • Rich (unregistered) in reply to zorro

    You're joking? Performance? If you want performance get your schema right, get your queries tuned like crazy (his query doesn't look like the fastest guy in town so that alone is killing the performance argument). This is where you'll save a lot of time. Then use caching a lot if it's still slow, and to generate the html just use a basic programming laguage that's fast with strings (perl, or even C if you feel like hurting yourself); but don't do that piece of WTF sqlHTML. (sorry for the double post, the previous message's html was bad).

     

    I would love to see cached blobs.  That would be funny.  An 'awe'some performance tip from you there.[^o)]

  • (cs) in reply to foxyshadis
    foxyshadis:
    zorro:
    sorry for the html horror above, apparently safari on os x is not the tool of choice for this site (quire ironic wtf in itself).

    It's okay, DailyWTF hates equally on all browsers. The stars and planets have to be aligned just right for quotes to work.


    No, no, no.  We've been over this before.  You need to sacrifice a dozen live virgin chickens at the stroke of midnight during a blue moon.
  • (cs) in reply to diaphanein

    Now storing your HTML (template) in a database is faster than reading it from disk, assuming your system lacks good caching (which IIS5&6 do well by default, but *NIX/Apache needs to be configured).

    Of course this guy isn't storing his template, he's storing html pieces, this is definetly my top 3 bad ideas I've ever seen on here.

  • (cs) in reply to Fregas
    Anonymous:

    My last job, they almost went that far: they used cursors in stored procedures to generate HTML and I think they actually did email it from there.  Genius!

    That actually makes a bit more sense;  it's not uncommon to send emails as the result of a scheduled SQL job, and if you want HTML emails, that's pretty much the way to do it.

    When you've got an actual web-server involved, on the other hand, you might as well use it.

  • (cs) in reply to i am funny
    Anonymous:
    DZ-Jay:

    There seems to be a disconcerting number of people on this forum that lack basic reading comprehension skills.
    what

    Huh?
  • (cs) in reply to diaphanein
    Anonymous:

    emptyset:
    <font face="Courier New" size="2">certain substrings in variable names are classic indicators of Great Programming Skill (tm).  "blob" certainly falls into this category.</font>

    "blob" is actually a datatype in some DBMSes.  So is "CLOB" and "GLOB". These are large objects.  FileBlob actually makes a fair amount of sense.

    I love how people mock that which they do not understand.  There is a very simple reason for doing this.  Performance.  Yes, its harder to maintain, yes it abuses the database, but it can be significantly faster.  In old data-driven ASP pages, I used this technique a fair amount.  Not nearly to this degree, but I used it.  To save iterating in an interepretted language on my slow ASP host (I'm talking a dual 200 Mhz Pentium Pro), I used my mainframe DBMS host to generate some of my html.

    Response time to client before:  30s.  Response time after the change:  <1s.



    I too love how people mock that which they do not understand.  For instance, those who do not undertand that if they need to do something so HEINOUSLY UGLY in order to get decent performance in a simple web application, that their basic architecture is probably boned beyond belief. 

    We all know that the proper way to improve performance requires:

    1 barrell of live chickens.
    A dark and cloudy night.
    A very sharp knife. 
    A large plastic sheet.
  • EVan M. (unregistered) in reply to diaphanein
    Anonymous:

    emptyset:
    <font face="Courier New" size="2">certain substrings in variable names are classic indicators of Great Programming Skill (tm).  "blob" certainly falls into this category.</font>

    "blob" is actually a datatype in some DBMSes.  So is "CLOB" and "GLOB". These are large objects.  FileBlob actually makes a fair amount of sense.

    I love how people mock that which they do not understand.  There is a very simple reason for doing this.  Performance.  Yes, its harder to maintain, yes it abuses the database, but it can be significantly faster.  In old data-driven ASP pages, I used this technique a fair amount.  Not nearly to this degree, but I used it.  To save iterating in an interepretted language on my slow ASP host (I'm talking a dual 200 Mhz Pentium Pro), I used my mainframe DBMS host to generate some of my html.

    Response time to client before:  30s.  Response time after the change:  <1s.



    Firstly, there's a world of difference between generating "some" of your HTML code, and "all" of it, which this guy appearently did. And while I have no clue when this project you speak of took place, I'm left thinking that your employer let you work in this for how long, paying you how much, leaving him with something that may work, but is a horrid mess, rather than just taking what he speant on you and upgrading the webserver so that it can do what it's suppose to?
  • (cs) in reply to Cristian Berneanu

    Whoops, shame on me indeed !

  • squid (unregistered) in reply to Rich
    Anonymous:

    You're joking? Performance? If you want performance get your schema right, get your queries tuned like crazy (his query doesn't look like the fastest guy in town so that alone is killing the performance argument). This is where you'll save a lot of time. Then use caching a lot if it's still slow, and to generate the html just use a basic programming laguage that's fast with strings (perl, or even C if you feel like hurting yourself); but don't do that piece of WTF sqlHTML. (sorry for the double post, the previous message's html was bad).

     

    I would love to see cached blobs.  That would be funny.  An 'awe'some performance tip from you there.[^o)]


    don't cache blobs, just cache whatever makes sense, might save you some joints here and there, or couple of db calls.
  • Tobias Brox (unregistered)

    Programming code posted as images?  WTF?

  • (cs)

    well, hey!

    "It seems like the code of this thread is being made fun of.
    Gosh, does that mean all of my previous HTML generation through SQL batch scripts(not even in Sproc form) are to be made fun of? Ah~~~"

    Said one of old friends' of mine.


  • (cs) in reply to diaphanein
    Anonymous:

    "blob" is actually a datatype in some DBMSes.  So is "CLOB" and "GLOB". These are large objects.  FileBlob actually makes a fair amount of sense.

    I love how people mock that which they do not understand.  There is a very simple reason for doing this.  Performance.  Yes, its harder to maintain, yes it abuses the database, but it can be significantly faster.  In old data-driven ASP pages, I used this technique a fair amount.  Not nearly to this degree, but I used it.  To save iterating in an interepretted language on my slow ASP host (I'm talking a dual 200 Mhz Pentium Pro), I used my mainframe DBMS host to generate some of my html.

    Response time to client before:  30s.  Response time after the change:  <1s.



    the LOB types are in fact a part of the most recent SQL standard.

    As for the rest: It deserves to be mocked. Mercilessly. If your middle tier host is slow, you - tadah - GET A FASTER MACHINE! You don't change your system architecture to something less maintainable! If you can't get a faster machine, it's either a toy project (where WTF rules don't really apply) or a serious management WTF.
  • anon (unregistered)

    Whether you do the ugly string concatenation in a PL and load off only the DB queries to SQL or just do everything in SQL, really doesn't matter. If the PL is only used to glue strings together, and SQL, which you need anyway, can do that itself, where's the need for the PL and the "middle tier"?

    Now presenting such a "middle tier" that just tacks strings onto each other while doing no real work would be a true WTF... if that sort of code wasn't so damn easy to find.

  • Mark L. (unregistered)

    Hmmm, the only problem I see is that comments are missing.

  • drfish (unregistered) in reply to diaphanein

    I guess you never worked with IBM's Net.Data? pretty much what this is!

  • (cs)

    i've done the same thing too

    shame on me

    but not full tables, just <a> links, or <input buttons

  • Mr Motivator (unregistered) in reply to diaphanein

    Hi

  • Mr Motivator (unregistered) in reply to diaphanein
    Anonymous:

    emptyset:
    <FONT face="Courier New" size=2>certain substrings in variable names are classic indicators of Great Programming Skill (tm).  "blob" certainly falls into this category.</FONT>

    "blob" is actually a datatype in some DBMSes.  So is "CLOB" and "GLOB". These are large objects.  FileBlob actually makes a fair amount of sense.

    I love how people mock that which they do not understand.  There is a very simple reason for doing this.  Performance.  Yes, its harder to maintain, yes it abuses the database, but it can be significantly faster.  In old data-driven ASP pages, I used this technique a fair amount.  Not nearly to this degree, but I used it.  To save iterating in an interepretted language on my slow ASP host (I'm talking a dual 200 Mhz Pentium Pro), I used my mainframe DBMS host to generate some of my html.

    Response time to client before:  30s.  Response time after the change:  <1s.

  • mushawrelo (unregistered)

    Крутой заработок без вложений,первые деньги уже сегодня! https://vk.cc/c3Rmmr

Leave a comment on “SqlHtml”

Log In or post as a guest

Replying to comment #:

« Return to Article