473,569 Members | 2,772 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

blobs in table

Ike
I have blob fields in some tables - never more than one field in any table,
and never where a blob can be > 64k. I have inherited the code for this
project from someone else, and was considering investing considerable effort
in this case to move the blobs over to a separate table altogether.

I am wondering if it is worth it however. Is it disasterous to have a single
blob field (which frequently is merely null) in a table. I have three tables
that can have a single blob in them. Am I decieving myself thinking I can
allow this to be the architecture? Please give me your advice, Ike
Jul 20 '05 #1
2 1886
Ike wrote:
I have blob fields in some tables - never more than one field in any table,
and never where a blob can be > 64k. I have inherited the code for this
project from someone else, and was considering investing considerable effort
in this case to move the blobs over to a separate table altogether.

I am wondering if it is worth it however. Is it disasterous to have a single
blob field (which frequently is merely null) in a table. I have three tables
that can have a single blob in them. Am I decieving myself thinking I can
allow this to be the architecture? Please give me your advice, Ike


I'm also looking for how to do this.

MP.
Jul 20 '05 #2
I have found that including BLOB fields in a table that also contains CHAR
fields, the CHAR fields will be forced into VARCHAR fields. What I do is put
BLOBs into thier own table with a link identifier like so:

Table_1
id(bigint), blob_size(medin t), blob_id(bigint)

Table_2
blob_id(bigint) , blob_data(medbl ob)

and:

SELECT blob_size, blob_data FROM Table_1, Table_2 WHERE Table_1.id = ?? AND
Table_2.blob_id = Table_1.blob_id LIMIT 1

should give you the blob_size and blob_data where the blob_id's match...
Norman
--
Avatar hosting at www.easyavatar.com
"Mathieu Pagé" <ma************ **@GoogleEmailS ystem.com> wrote in message
news:OV******** ************@wa gner.videotron. net...
Ike wrote:
I have blob fields in some tables - never more than one field in any table, and never where a blob can be > 64k. I have inherited the code for this
project from someone else, and was considering investing considerable effort in this case to move the blobs over to a separate table altogether.

I am wondering if it is worth it however. Is it disasterous to have a single blob field (which frequently is merely null) in a table. I have three tables that can have a single blob in them. Am I decieving myself thinking I can allow this to be the architecture? Please give me your advice, Ike


I'm also looking for how to do this.

MP.

Jul 20 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
3355
by: Kirby Urner | last post by:
I've been testing the Cookbook example 8.6 (2002 edition) re using cPickle to insert and retrieve BLOBs from mySQL, using Python's MySQLdb module. When I try to cPickle.loads(blob), I get an error telling me that loads wants a string, not type array.array. So I go cPickle.loads(blob.tostring()) instead and it works. My question is: has...
0
2866
by: Ole Hansen | last post by:
Hi, I have a working application inserting rows to a table using the array interface. Now I want to insert BLOBs as well but OCIStmtExecute crashes when executed with BLOBs. For BLOB types I use OCIDescriptorAlloc() and uses this to allocate space for my data (app. 1Mb). Afterwards I store data in memory allocated by OCIDescripterAlloc.
1
15781
by: Jesse Wolgamott | last post by:
I've seen plenty of posts regarding the estimation of table size, usually in the processing of planning for server storage needs. Well, I've got a different problem. I need to know how much data each of our Customers are using in a Database. (1 SQL DB stores multiple customers). Basically, I want to be able to say: Customer A: 45.5 MB,...
7
6902
by: Howard Lowndes | last post by:
My situation is that I am interacting PHP 4.1.2 to PostgreSQL 7.2.2 I have no difficulty inserting and managing BLOBs into the Large Object system table, and I have a user table called images which maintains the relationship between the BLOB loid and the identity that relates to it in my user tables. So far so good. When I RTFM obout...
0
1246
by: omkar prabhu | last post by:
i am using postgres 7.0.3 and also postgres 7.2.1 I am new towards using blobs,I want to transfers records with blobs from a table to different database(postgres) using perl without extracting the blob to disk(i.e without using lo_export/lo_import). Below is my perl script which is not working can
0
1305
by: .Net Newbie | last post by:
I am currently working with the C# version of the PortalSDK in a text editor and have run across a bug that I need to resolve in order for my app to function properly. Basically, I'm using the Documents section to load Blobs into the Portal Database on SQL Server. When I upload small binary documents everything works fine. However, when I...
2
2798
by: Jerry LeVan | last post by:
Hi, I am just getting into large objects and bytea "stuff". I created a small db called pictures and loaded some large objects and then tried to do a restore. Here is how I got the dump. pg_dump -Fc -b pictures > /Users/jerry/desktop/db.comp
2
5312
by: Connie | last post by:
We have a blob in one table that is storing pdf files. I need to write a select query that will grab that column and write those *.pdf files out to a location on my hard drive. Does anyone know how that can be done? All suggestions would be greatly appreciated....
5
16328
by: bhodgins | last post by:
Hi, I am new on here, and had a newbie question that I am stumped with. I am not new to access, but am new to VB. I am trying to export BLOBs from a field called photo to external jpeg files. I have tried the MS kb 210486 and successfully got the import/export to work with a sample table, but only the first record. I do not wish to impost...
0
7697
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
1
7672
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7968
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
6283
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
1
5512
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
3640
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2113
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1212
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
937
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.