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.

7634 questions
530
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:
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
  • 6,469
  • 6
  • 27
  • 28
299
votes
10 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
  • 5,344
  • 5
  • 30
  • 36
251
votes
9 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
  • 12,193
  • 32
  • 113
  • 153
245
votes
9 answers

How to get a file or blob from an object URL?

I am allowing the user to load images into a page via drag&drop and other methods. When an image is dropped, I'm using URL.createObjectURL to convert to an object URL to display the image. I am not revoking the url, as I do reuse it. So, when it…
BrianFreud
  • 7,094
  • 6
  • 33
  • 50
170
votes
2 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
  • 38,977
  • 9
  • 43
  • 59
157
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,847
  • 3
  • 26
  • 28
144
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
  • 26,343
  • 56
  • 205
  • 333
141
votes
7 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
  • 3,580
  • 22
  • 82
  • 146
140
votes
12 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
  • 8,301
  • 11
  • 55
  • 73
139
votes
10 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,437
  • 6
  • 32
  • 52
139
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,621
  • 3
  • 14
  • 15
118
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
  • 5,455
  • 11
  • 54
  • 95
114
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 Mafuxwana
  • 3,702
  • 6
  • 41
  • 59
105
votes
5 answers

Javascript - I created a blob from a string, how do I get the string back out?

I have a string that I called Blob() on: var mystring = "Hello World!"; var myblob = new Blob([mystring], { type: 'text/plain' }); mystring = ""; How do I get the string back out? function getBlobData(blob) { // Not sure what code to put…
Joey
  • 10,504
  • 16
  • 39
  • 54
1
2 3
99 100