A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Database Design
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

"free" ip number when I remove device from database, not delete?



 
 
Thread Tools Display Modes
  #1  
Old May 11th, 2010, 07:22 PM posted to microsoft.public.access.tablesdbdesign
Sandroid[_2_]
external usenet poster
 
Posts: 1
Default "free" ip number when I remove device from database, not delete?

Win 7, access 2007 , tables: device and ip, relation (device.ipIP,
foreign)one-to-one(ip.ID, primary)

when I delete an device from device table using form it is also deleted
from IP table. This should work such as the IP address remains to be
used in other device . How to resolve this? If I change the relation
there is no more validatation that one IP address is used once.

I want to "free" ip number when I remove device from database so IP number is
not deleted and can be used later. How to accomplish this?
In relation the cascading is turned off - no help
referential integrity turned off - no help
relation deleted, it still removes row from IP table when I remove one device
using the form.

In the form the dropdown control looks for "free" addresses as follows:
SELECT tblIP.ID, [ip] & "." & [ip2] & "." & [ip3] & "." & [ip4] AS
[IP-
number], tblDevice.ipID
FROM tblIP LEFT JOIN tblDevice ON tblIP.ID = tblDevice.ipID
ORDER BY tblIP.ip, tblIP.ip2, tblIP.ip3, tblIP.ip4
WHERE (((tblDevice.ipID) Is Null));

I don't want to delete IP address from tblIP, tried to make lookup
table from IP table without relation, no help? how to make make sure that
each ip address is used only once then?

tblIP structu ID(primary),ip, ip2, ip3, ip4.


I deleted the relation and drag from IP table (ID, primary key)
to device table (ipID, foreign key) but it still removes the related IP
row when I remove row from device table. When I try to drag from device
table it gives me error (not originally in english) like "field name
in index or relation definition "id" is not valid" What to do?

Help me, Please!

  #2  
Old May 11th, 2010, 07:38 PM posted to microsoft.public.access.tablesdbdesign
BruceM via AccessMonster.com
external usenet poster
 
Posts: 448
Default "free" ip number when I remove device from database, not delete?

There is an active thread on this same topic in the Forms group.

Sandroid wrote:
Win 7, access 2007 , tables: device and ip, relation (device.ipIP,
foreign)one-to-one(ip.ID, primary)

when I delete an device from device table using form it is also deleted
from IP table. This should work such as the IP address remains to be
used in other device . How to resolve this? If I change the relation
there is no more validatation that one IP address is used once.

I want to "free" ip number when I remove device from database so IP number is
not deleted and can be used later. How to accomplish this?
In relation the cascading is turned off - no help
referential integrity turned off - no help
relation deleted, it still removes row from IP table when I remove one device
using the form.

In the form the dropdown control looks for "free" addresses as follows:
SELECT tblIP.ID, [ip] & "." & [ip2] & "." & [ip3] & "." & [ip4] AS
[IP-
number], tblDevice.ipID
FROM tblIP LEFT JOIN tblDevice ON tblIP.ID = tblDevice.ipID
ORDER BY tblIP.ip, tblIP.ip2, tblIP.ip3, tblIP.ip4
WHERE (((tblDevice.ipID) Is Null));

I don't want to delete IP address from tblIP, tried to make lookup
table from IP table without relation, no help? how to make make sure that
each ip address is used only once then?

tblIP structu ID(primary),ip, ip2, ip3, ip4.

I deleted the relation and drag from IP table (ID, primary key)
to device table (ipID, foreign key) but it still removes the related IP
row when I remove row from device table. When I try to drag from device
table it gives me error (not originally in english) like "field name
in index or relation definition "id" is not valid" What to do?

Help me, Please!


--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...esign/201005/1

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 04:39 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.