[Solved] Can't create relationships between tables

Discuss the database features
Post Reply
markb
Posts: 3
Joined: Mon May 12, 2008 7:33 pm

[Solved] Can't create relationships between tables

Post by markb »

Problem: can't create relationships between tables. I also can't create a primary key, and can't create a field of type "integer"; I don't know for sure that these issues are related, but it seems so from my web searching.

Attempted so far: I've pasted data from Calc, and created tables both from scratch and using the wizard. The option to create a primary key when pasting Calc data is greyed out. When editing a table, right-clicking on the field border to get the context menu doesn't bring up the option to create a primary key. When I select the TOOLS/RELATIONSHIPS menu item, I receive the message, "The database does not support relations".

I have Windows XP.
Last edited by markb on Tue May 13, 2008 3:21 pm, edited 1 time in total.
User avatar
kabing
Volunteer
Posts: 680
Joined: Fri Nov 23, 2007 12:05 am
Location: Midwest, USA

Re: Can't create relationships between tables

Post by kabing »

With the database document in question open, that does it say at the very bottom of the window, in the status bar?

kabing
NeoOffice 2022.7 LibreOffice 24.8.4 on (Intel) Mac OS Ventura
markb
Posts: 3
Joined: Mon May 12, 2008 7:33 pm

Re: Can't create relationships between tables

Post by markb »

The far left shows "dBASE"; the status area to the right of that shows the location of the db.
User avatar
kabing
Volunteer
Posts: 680
Joined: Fri Nov 23, 2007 12:05 am
Location: Midwest, USA

Re: Can't create relationships between tables

Post by kabing »

That's the problem. The dBase format doesn't support relationships or primary keys.

Try this:

Create a new Base document. Make sure that the radio button next to "Create a new database" is selected when the Database Wizard window opens.

In the main document window for the old database ( the one that says dBase), select Tables in the left column. Right-click on one of the tables and select Copy. Switch to the new database document, select Tables in the left column, right-click and select paste.

A Wizard should open; you should now be able to either specify a primary key field in the wizard or tell the wizard to create a primary keyfield for you.

kabing
NeoOffice 2022.7 LibreOffice 24.8.4 on (Intel) Mac OS Ventura
markb
Posts: 3
Joined: Mon May 12, 2008 7:33 pm

Re: [Solved] Can't create relationships between tables

Post by markb »

That did it! Thanks for your help, kabing.
Post Reply