By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
429,500 Members | 830 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 429,500 IT Pros & Developers. It's quick & easy.

need a little help with creating database

P: n/a
Hello!

I am in the process of creating a database listing tours, something
similar to what you can find on www.infohub.com.

This means that I need to create a database which can be searchable
with destination, category, price and so forth. Unfortunately I can
not seem to be able to create the relationships, neither can I make my
head learn how to do this. I would be extremely happy if anyone could
help me solve this problem for me or at least help me a little on the
way!
Thanks a lot!
Erik
Nov 12 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
do you have any tables defined yet ?
which relationship(s) are you having trouble with ?

here's a quick start...

tblRegion
regionId
region

tblCountry
countryId
country
regionId

tblArea (state, province, region, county)
areaId
area
countryId
parentAreaId (county within a state, city within a province)

tblActivity
activityId
activity
startDate
endDate
dailyRate
weeklyRate

tblContact
contactId
name
address
areaId
phone
fax
email
etc

tblRental
rentalId
rental
rental type (lodge, hotel, ranch, resort)
contactId
marketingDocumentLink
webSiteLink

tblRentalActivity
rentalId
activityId
contactId

er**@freestyletravel.no (Erik Thorsen) wrote in message news:<ed**************************@posting.google. com>...
Hello!

I am in the process of creating a database listing tours, something
similar to what you can find on www.infohub.com.

This means that I need to create a database which can be searchable
with destination, category, price and so forth. Unfortunately I can
not seem to be able to create the relationships, neither can I make my
head learn how to do this. I would be extremely happy if anyone could
help me solve this problem for me or at least help me a little on the
way!
Thanks a lot!
Erik

Nov 12 '05 #2

P: n/a
Hello Roger!

Thanks for getting back to me so quickly. Here is what I have got so
far:

tblTours
tourId
description
longdescription
image1
image2
baseprice

tblCategories
categoryId
categoryname

tblDestinations
destinationId
destinationname

tblOptions
optionsId
optGroup
optName
optPriceDiff
optWeightDiff

I am aware that I probably need to create a junction table or something
like that but I can't seem to get things working. I need each tour to be
available to several different categories and at the same time available
for different destinations.
Like the tour Scandinavian Capitals. This tours goes to Norway, Sweden,
Denmark and Finland. The tour includes husky safari, fishing, cruising,
sightseeing and fjord tour. So somehow I need to make this work by
setting my database up in a many to many relationship way I guess but I
have tried so many times I guess I am as blind as batman right now...
:-) Hope you can help me! Thanks!


*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 12 '05 #3

P: n/a
Erik Thorsen <er**@freestyletravel.no> wrote in message news:<40***********************@news.frii.net>...
Hello Roger!

Thanks for getting back to me so quickly. Here is what I have got so
far:

tblTours
tourId
description
longdescription
image1
image2
baseprice

tblCategories
categoryId
categoryname

tblDestinations
destinationId
destinationname

tblOptions
optionsId
optGroup
optName
optPriceDiff
optWeightDiff

I am aware that I probably need to create a junction table or something
like that but I can't seem to get things working. I need each tour to be
available to several different categories and at the same time available
for different destinations.
Like the tour Scandinavian Capitals. This tours goes to Norway, Sweden,
Denmark and Finland. The tour includes husky safari, fishing, cruising,
sightseeing and fjord tour. So somehow I need to make this work by
setting my database up in a many to many relationship way I guess but I
have tried so many times I guess I am as blind as batman right now...
:-) Hope you can help me! Thanks!


tblTourCategories
TourID (PK1)
CategoryID (PK2)

tblTourDestinations
TourID(PK1)
DestinationID(PK2)

just take the two PKs from the other tables, make them the joint PK of
the join table, and that's it. And change the type from autonumber to
long.
Nov 12 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.