Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Delete record ?
Message
From
21/04/2004 10:38:20
 
General information
Forum:
Visual FoxPro
Category:
Client/server
Title:
Miscellaneous
Thread ID:
00896769
Message ID:
00896890
Views:
12
Hi Fabio

The problem is that you have set a relationship in SQL Server"FK_phones_Firms" where Clients.Id is the Primary PK table and Firms.ID is the Foreign key table and checked cascade update and cascade delete related filed....so if u delete client , firm will have no reference
Hope you understand me ....

Patrick


>I create a CA based on ADO to connect to SQL Server DB
>Here the Select CMD:
>
>SELECT Firms.name, Clients.Id, Clients.Phone FROM Clients LEFT OUTER JOIN Firms ON Clients.Firm = Firms.Id
>
>Field Name is not marked as Updatable or Key Field
>
>Firms has CONSTRAIN index to other tables, when I DELETE IN CA TableUpdate() gives me a error:
>1435
>Microsoft OLE DB Provider for SQL Server : DELETE statement conflicted with COLUMN REFERENCE constraint 'FK_phones_Firms'. The conflict occurred in database 'task', table 'phones', column 'firm'.
>
>but I don't want to delete the firm, I want just to remove it from Clients table, why CA try to delete the record in Firms?
>How can I delete a record in Clients w/o CA delete the record in Firms?
>By the way when I refresh Coursor After Error The record is removed.
>
>TIA
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform