Mar 262013
 
 March 26, 2013  Posted by at 10:15 pm Not So Stupid Questions  Add comments

[To celebrate my first year of programming I will ask a ‘stupid’ questions daily on my blog for a year, to make sure I learn at least 365 new things during my second year as a developer]

LOB, when storing large objects :)

LOB, when storing large objects 🙂

Try saying that fast 10 times! I was talking on Skype with a friend that is learning programming, and we started talking about storage and SQL server. I mentioned BLOB and after a giggle was asked what that is. For a short definition, this is how I explained it:

LOB stands for Large Object and it’s a data type that are for storing large objects. BLOB stands for Binary Large Object and is in binary format- and it’s not uncommon to see images stored that way. CLOB stands for Character Large Object and allows us to store string data in database character set format. Often BLOB is used to refer to both BLOB and CLOB

The nest question is, should we store large images as BLOB’s, or save them on a filesystem and store the path instead? That question is coming up very soon, but I would love to hear what you think 🙂

  4 Responses to “Stupid Question 169: LOB, BLOB and CLOB – what are those?”

  1. Only in BLOB:
    1. because we got all information in 1 place
    2. Someone can change path
    3. Somebody can don’t have permission to path

  2. LOB in my field stands for Line-Of-Business . I never called a Character Large Object a CLOB. In my vocabulary they are all BLOBs. No matter if they contain image (binary) or text (which at the end of the day is also binary) data.
    Regarding your hinted second question:
    my answer: it depends!
    Want to make it easy to copy databases around? put the images into the database. Want to access the images also directly via the filesystem (browsable), put them into the filesystem and add a link to the database. but then maybe only put a relative path plus a configuration that says where to start.
    Once again, my 2cts.

    Roman
    @Roman_D_Mueller

  3. Regarding images, I think it depends on how you’re using them. If you can get away with lazy-loading and just run around with image metadata you can better leverage the power of the FS. If you want to push your images around with your BD backup strategy or otherwise handle them akin to the rest of your data, then BLOB it up.

  4. On Images I would say store the CDN link and load them to a CDN solution is the most common usage I have. Just because serving the images from the CDN reduces my database size and allows me to bypass the access issue.

 Leave a Reply

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

(required)

(required)

What is 11 + 5 ?
Please leave these two fields as-is:
IMPORTANT! To be able to proceed, you need to solve the following simple math (so we know that you are a human) :-)