469,921 Members | 2,179 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,921 developers. It's quick & easy.

Table structure & relatinships with OLE Objects

Hi all

I am a real pled here, so I am not entirely sure how to structure my question so I will just tell you what I want to achieve and what I have done and see if there is a solution.

The information is in relation to fish, so I will describe in short the information and their releationship.

What I am wanting to do is to display all of the fields in both tables on a single form and to be able to scroll through them using the data navigator as per normal.

A fish may have a single scientific name, but may have many common names.
A fish may have a single form.
The form has a name, description and an image (BLOB)
A fish may have multiple images (BLOB)

To achieve this I have created 2 tables. I created 2 tables because the BLOB in the tblForms is common so I saw no point in putting multiple instances of the same image in a single table.

ScientificName (text)
CommonName (text)
Image1 (OLE Object)
Image2 (OLE Object)
Image3 (OLE Object)
Image4 (OLE Object)

FormName (text)
FormDesc (text)
FormPic (OLE Object)

In actual fact I have around 10 tables, but this is the part I am having issues with. The rest works satisfactorily and I have been able to create the respective relationships.

In fact it would be great if I could place all the Images from the tblFish into a serparate table and create a separate navigator just for those on the same form. Not sure if that is even possible though. Doing that would reduce realestate on the screen.

I don't know how to create the realtionship between the 2 tables so that I can build the form to display all of the information.

Ultimately this will be the backend DB for a VB application.

If I am going about this all the wrong way then I would like to know now.

Any thoughts and/or comments would be most helpful.

Many thanks in advance

Oct 7 '08 #1
2 1316
2,653 Expert 2GB
Hello, Fred.

I suggest you to read Database Normalization and Table Structures article.

Also, you may find some interesting info in The BLOB (not the movie!), but first of all you should redesign your tables.

Oct 8 '08 #2
32,231 Expert Mod 16PB
How appropriate it is to be pointed in the right direction by Fish himself :D

Read the article. It is actually very good, and aimed at beginners and experienced database programmers alike.

As far as your design is concerned, consider that whenever you have the opportunity to have multiple possible items related to any individual item, it is better to store them in a separate table and link them, than trying to store them within the same table.

I hope that makes sense, and Do read the article anyway.

Welcome to Bytes!
Oct 8 '08 #3

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

1 post views Thread by mksql | last post: by
19 posts views Thread by Thomas Matthews | last post: by
10 posts views Thread by Peter Kirk | last post: by
5 posts views Thread by xah | last post: by
2 posts views Thread by Dave Ekhaus | last post: by
4 posts views Thread by =?iso-8859-1?B?UmVu6SBKZW5zZW4=?= | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.