Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Wierd Bug
Message
De
21/08/2001 02:55:39
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
Wierd Bug
Divers
Thread ID:
00546586
Message ID:
00546586
Vues:
44
Hey, its this a bug to everyone else? Is there a better way to work around it. If I comment out teh BEGIN TRANSACTION and ROLLBACK, the error doesn't occur, if I comment out opening up that child table, the error doesn't occur, and if I SELECT table1 right before the TABLEUPDATE() the error doesn't occur. (Code makes directory on your C drive).

CLOSE DATABASES all

IF NOT DIRECTORY('c:\vfptest\testrule')
MD c:\vfptest\testrule
ENDIF
CD c:\vfptest\testrule
DELETE FILE *.*
CREATE DATABASE testrule

CREATE TABLE table1 (field1 i, name c(10) CHECK not EMPTY(name) ERROR 'Name cannot be empty')
CREATE TABLE parent1 (field1 i DEFAULT 1)
CREATE TABLE child1 (field1 i)

USE IN table1
USE IN parent1
USE IN child1

USE parent1
CURSORSETPROP("Buffering", 3)
USE table1 IN 0
CURSORSETPROP("Buffering", 3, 'table1')
USE child1 IN 0
CURSORSETPROP("Buffering", 3, 'child1')
SET RELATION TO field1 INTO table1
SET RELATION TO field1 INTO child1 IN table1

* Adding an item also adds a Cross Reference
APPEND BLANK IN parent1

SELECT table1
INSERT INTO table1 (field1) VALUES (parent1.field1)
SELECT parent1

BEGIN TRANSACTION
TABLEUPDATE(2, .F., 'table1')
ROLLBACK
WAIT WINDOW ALIAS(1)
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform