close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

linked table question

Thread began 10/07/2010 7:35 am by i.edwards384429 | Last modified 10/08/2010 12:01 pm by Jason Byrnes | 1795 views | 7 replies |

i.edwards384429

linked table question

Hi

I've created a table containing details about boats, I've used this module to build the pages to display boats picked by the various criteria,- so far so good.

As each of the boats can have a separate of the same owner I created another table holding name,address etc .

On each table I added a field called sellerId thinking I could link them as in Alpha5, access etc . I seem unable to locate the way to do this.

Would I do better to do it all on one table and have multiple entries for eacch boat owner?

thanks

Ian

Sign in to reply to this post

Jason ByrnesWebAssist

Can you provide some more details on the type of relationship you are trying to create.

is it a many to one relationship?
One owner to many boats?


if this is the case

In the Boats table add a ownerID column. this column will be numeric. in this column add the value from the Primary Key Column of the Owners table to create the relationship of owner to boat.

Sign in to reply to this post

i.edwards384429

update

Hi Jason

yes your surmise is correct. One owner many boats and I 'm using ( well I will use) the Data assist package to create the search and update pages etc.

I tried to do as you said but when I set the field to numeric it accepts but when I save it alters the numeric field to decimal.

I've sql-dddd and ziped up the vast database ( ok two tables)

can you take a look and see what I've done wrong.

thanks

Ian

Attached Files
boats.zip
Sign in to reply to this post

Jason ByrnesWebAssist

use int for the column type.

Sign in to reply to this post

i.edwards384429

Calrification

Hi Jason

at the risk of appearing even more stupid how do I

"add the value from the Primary Key Column of the Owners table to create the relationship of owner to boat. "

thanks

Ian

Sign in to reply to this post

Jason ByrnesWebAssist

on the page where you are inserting the boat to the database, create a recordset to return the owner name and owner ID

Create a select list that uses the owner recordset. Set the value to use the owner ID column, and the label to use the owner name column

In the insert record behavior, bind the OwnerId column in the boats table to the select list you create.

Sign in to reply to this post

i.edwards384429

update

thanks Jason

Like an idiot I was trying to do it in phpmyadmin! thought it was like a conventional database set

Have a good holiday monday

Ian

Sign in to reply to this post

Jason ByrnesWebAssist

you're welcome.

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...