Questions tagged [blob]

A BLOB is a collection of binary data stored as a single entity in a database management system.

A BLOB (binary large object, basic large object, BLOB, or BLOb) is a collection of binary data stored as a single entity in a database management system. Blobs are typically images, audio or other multimedia objects, though sometimes binary executable code is stored as a blob.

Beyond that, the term BLOB has various slightly related usages, see wikipedia for further examples.

6734 questions
415
votes
56 answers

Storing Images in DB - Yea or Nay?

So I'm using an app that stores images heavily in the DB. What's your outlook on this? I'm more of a type to store the location in the filesystem, than store it directly in the DB. What do you think are the pros/cons?
James Hall
  • 5,698
  • 6
  • 24
  • 27
352
votes
9 answers

How do we download a blob url video

I want to download a video whose URL is not a simple MP4 file, but rather a blob type for example:
229
votes
8 answers

JavaScript blob filename without link

How do you set the name of a blob file in JavaScript when force downloading it through window.location? function newFile(data) { var json = JSON.stringify(data); var blob = new Blob([json], {type: "octet/stream"}); var url =…
Ash Blue
  • 4,249
  • 4
  • 25
  • 33
157
votes
3 answers

What is the maximum length of data I can put in a BLOB column in MySQL?

What is the maximum length of data I can put in a BLOB column in MySQL?
Newy
  • 34,169
  • 9
  • 40
  • 55
146
votes
8 answers

How to convert Blob to File in JavaScript

I need to upload an image to NodeJS server to some directory. I am using connect-busboy node module for that. I had the dataURL of the image that I converted to blob using the following code: dataURLToBlob: function(dataURL) { var BASE64_MARKER…
skip
  • 10,691
  • 27
  • 99
  • 146
125
votes
8 answers

proper hibernate annotation for byte[]

I have an application using hibernate 3.1 and JPA annotations. It has a few objects with byte[] attributes (1k - 200k in size). It uses the JPA @Lob annotation, and hibernate 3.1 can read these just fine on all major databases -- it seems to hide…
Justin
  • 4,271
  • 4
  • 29
  • 52
123
votes
6 answers

What are the differences between the BLOB and TEXT datatypes in MySQL?

What is blob and what is text? What are the differences? When do I need to use blob and when do I need text as data type? Because for blob and text, there are mediumblob == mediumtext, smallblob == small text. Do they even have the same meaning? And…
nencor
  • 1,451
  • 2
  • 12
  • 15
118
votes
11 answers

How do I get textual contents from BLOB in Oracle SQL

I am trying to see from an SQL console what is inside an Oracle BLOB. I know it contains a somewhat large body of text and I want to just see the text, but the following query only indicates that there is a BLOB in that field: select BLOB_FIELD from…
Roland Tepp
  • 7,673
  • 10
  • 53
  • 68
118
votes
7 answers

How to go from Blob to ArrayBuffer

I was studying Blobs, and I noticed that when you have an ArrayBuffer, you can easily convert this to a Blob as follows: var dataView = new DataView(arrayBuffer); var blob = new Blob([dataView], { type: mimeString }); The question I have now is, is…
Jeanluca Scaljeri
  • 19,619
  • 37
  • 147
  • 259
112
votes
7 answers

Using JavaScript to display a Blob

I am retrieving a Blob image from a database, and I'd like to be able to view that image using JavaScript. The following code produces a broken image icon on the page: var image = document.createElement('image'); image.src =…
GAgnew
  • 3,325
  • 3
  • 22
  • 28
111
votes
8 answers

How to Display blob (.pdf) in an AngularJS app

I have been trying to display pdf file which I am getting as a blob from a $http.post response. The pdf must be displayed within the app using for example. I came across a couple of stack posts but somehow my example doesn't seem to…
Simo D'lo Mafuxwana
  • 3,204
  • 6
  • 37
  • 53
109
votes
6 answers

Convert blob URL to normal URL

My page generates a URL like this: "blob:http%3A//localhost%3A8383/568233a1-8b13-48b3-84d5-cca045ae384f" How can I convert it to a normal address? I'm using it as an 's src attribute.
Jacob
  • 5,004
  • 18
  • 67
  • 130
108
votes
3 answers

Difference between CLOB and BLOB from DB2 and Oracle Perspective?

I have been pretty much fascinated by these two data types. According to Oracle Docs, they are presented as follows : BLOB : Variable-length binary large object string that can be up to 2GB (2,147,483,647) long. Primarily intended to hold…
The Dark Knight
  • 4,986
  • 10
  • 42
  • 86
82
votes
1 answer

dbms_lob.getlength() vs. length() to find blob size in oracle

I'm getting the same results from select length(column_name) from table as select dbms_lob.getlength(column_name) from table However, the answers to this question seem to favor using dbms_lob.getlength(). Is there any benefit to using…
user285498
79
votes
19 answers

How to DEFLATE with a command line tool to extract a git object?

I'm looking for a command line wrapper for the DEFLATE algorithm. I have a file (git blob) that is compressed using DEFLATE, and I want to uncompress it. The gzip command does not seem to have an option to directly use the DEFLATE algorithm, rather…
Felix Geisendörfer
  • 2,522
  • 4
  • 25
  • 31
1
2 3
99 100