From: Meesh on
I am designing a form to input both sides of connections between ports. We
have I have a table of Ports which has the key field as the ID numbers. On
this table of ports we have device ids as well so each of the IDs are unique.

On the form to input both sides of the ports, unfortunately it is going to
use the same table. However I am getting an error msg that you can change
the auto ID number, when i try to select one.

I'm EXTREMELY and utterly new to anything access.
From: Stefan Hoffmann on
hi,

On 11.03.2010 15:01, Meesh wrote:
> I am designing a form to input both sides of connections between ports. We
> have I have a table of Ports which has the key field as the ID numbers. On
> this table of ports we have device ids as well so each of the IDs are unique.
>
> On the form to input both sides of the ports, unfortunately it is going to
> use the same table. However I am getting an error msg that you can change
> the auto ID number, when i try to select one.
>
> I'm EXTREMELY and utterly new to anything access.
As you have not posted an accurate description of your table structure,
I have to guess.

Normally you would have three tables:

Device:
ID, AutoNumber, PrimaryKey, Not Null
DeviceName, Text(255), Unique Index, Not Null, Not Empty

Port:
ID, AutoNumber, PrimaryKey, Not Null
idDevice, Number(Long), Foreign Key to Device.ID, Not Null
PortName, Text(255), Not Null, Not Empty

PortAssignment:
ID, AutoNumber, PrimaryKey, Not Null
idPortA, Number(Long), Unique Index, Foreign Key to Port.ID, Not Null
idPortB, Number(Long), Unique Index, Foreign Key to Port.ID, Not Null

The unique index in the assignment table is necessary as each port can
only be used once.

Does this apply to your situation?


mfG
--> stefan <--
 | 
Pages: 1
Prev: Access file types?
Next: If And Statement