Creating a relationship

A place for users and developers of the Xataface to discuss and receive support.

Creating a relationship

Postby blange » Tue Mar 09, 2010 3:17 pm

I'm a xataface newbie trying to create my first relationship. I have a one to many relationship between Categories and Services. I thought all I needed to do was to go into /tables/category/relationship.ini and add

[Services]
service.category_id = "$id"

The primary key in the Categories table is 'id'. Am I doing something wrong? Is there any kind of cache I need to delete?

Thanks,

Brian
blange
 
Posts: 6
Joined: Tue Feb 09, 2010 12:51 pm

Re: Creating a relationship

Postby shannah » Tue Mar 09, 2010 3:22 pm

I suspect that your problem is to do with table names.

E.g. you mention that the relationship is between tables named "Categories" and "Services". Yet in your relationship you are referring to a table named "service".
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Re: Creating a relationship

Postby blange » Tue Mar 09, 2010 3:26 pm

My tables are lower case "service" and "category".
Should I be getting any kind of error message? I don't seem to be.

By creating the relationship I am hoping to see the Category Name when in the "List View" for Service.
Is this what should happen?
blange
 
Posts: 6
Joined: Tue Feb 09, 2010 12:51 pm

Re: Creating a relationship

Postby shannah » Tue Mar 09, 2010 3:36 pm

You won't see the relationship in list view. In details view, you should see an additional tab for your relationship. "View", "Edit", and now "Services"
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Re: Creating a relationship

Postby blange » Tue Mar 09, 2010 3:52 pm

I do see it. Thanks for the help!
blange
 
Posts: 6
Joined: Tue Feb 09, 2010 12:51 pm


Return to Xataface Users

Who is online

Users browsing this forum: No registered users and 30 guests

Powered by Dataface
© 2005-2007 Steve Hannah All rights reserved