Jump to content

This topic is 7079 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

Hey guys, Im new to Filemaker and am stuck with a database I'm trying to design. Basically, I need to record dates that adverts were placed along with the details of the adverts (size, price etc). I then need a simple report, so that I can choose a date, and the report lists the details of the ads that were placed on that date.

I've tried the help file, and the Filemaker Bible but I'm not sure what I should be looking for. I can design the layout fine, but Im not sure what sort of field I should use for the dates, and hw to make the report.

I hope this describes the problem okay.

Cheers

Posted

Uh....at the moment none. I didn't want to start everything again if I couldn't get it working. I dont think I was too clear in my first post. I am designing an advertising database for a real estate mob. Each record is made up of a property with its details etc. I can manage to do this no probs. When we place and ad for it, I need to select a date, and enter the ad size and cost. the following weeks, I need to enter a new date, and size and cost etc. Once I've set this up I can make some simple reports - the main one being able to select a date and have all relevants ads appear in the report. I've read that maybe portals, or repeating fields might be the way to go. It's a bit of a brain bender at the moment. I've looked through the manual, but not really too sure what section I should be reading?

Thanks for your help.

Posted

You should have two tables. One would be for your properties, and the other for your advertisements.

You can have a button on the main interface for your properties create a new related record in the advertising table.

Each record you create in the properties table should have its own unique serial value. Then you will have another field in the Advertisements table called PropertyID or something. Match your relationship on this field. This will now show all the Advertisements related to the current property you are viewing. you can use a portal based off the relationship to view them if you wish.

To have a report show all the Advertisements from a certain date, you can do a find in the advertisements layout on the date. Then you can use the new enhanced Go to Related Records feature of FM8 where you can show related records of and match on current found set back to the Properties interface.

Posted

Here take a look at the quick mockup that I did. You dont have to do it exactly this way, its just gives you an idea.

Also, You should really read the whitepaper by David Kachel. It will probably help you a lot.

http://www.codemastersworkshop.com/downloads.html

Good luck.

prop.zip

Posted

Just a suggestion. As you seem to be very new to database design I would recommend the book "Using Filemaker 7" by Steve Lane. It not only covers the basics and advanced programming for filemaker, it also covers the theories of database design. Really good book - way better than the FM bible.

Posted

One more thing (sorry to be a pain). I have attached the database below with some small changes I made from the one posted above. I'm really please so far with how its going to work out. Where I'm stuck is I'd like to associate an some advertising text and 4 photos with each ad. As you can see I've set up the portal with a button called "details". when you click on this I want it to open a layout that shows the ad details, with the text and the 4 photos that were added. I can then start producing some reports.

Thanks again

prop2.zip

Posted (edited)

Create a new ID key in the Advertising table AdID. This should be a serial key as well. I should have set it up for you in my previous example, as I usually create a Uniq key for every single table I create... Dunno why I missed it this time. :qwery:

Anyway, create another table called images. Create a uniq key called ImageID, and also two other fields, a container field for your image, and a number field called AdvID. Match Advertising::AdID to Image::AdvID.

Now when you click on the details button, you can have a script to open a new window and showing related records to that Ad. If the text is associated with each picture you can have a field in this table called pictureTxt or if its for the entire ad itself, you can create that field in the Advertising Table.

Edited by Guest
typo
Posted

Last thing. Everything is now setup and working great. The only prob I have is when I delete a record it doesn't delete the information that is stored in the portals. This means that when i view some of my reports it's showing data that should have already been deleted. At the moment I'm using a simple button that runs a "Delete Record" script.

Cheers

Posted

AArdvaark,

Got to your relationship graph, double click on the relationship in question and bottom right and left there is a check box 'delete records in this table etc..'.

Check the box on the side of the relationship that your portal records come from

Phil

This topic is 7079 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.