Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
CursorAdapter Builder Issue
Message
 
 
À
21/01/2004 16:38:33
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00869241
Message ID:
00875928
Vues:
27
Done! I just put up the new revised version.

http://www.mctweedle.com/downloads/cabuilder.zip

>Hi Mark,
>
>I discovered the following scenario which causes the caBuilder to error out:
>
>One of the SQL Server tables in a DB we have contains just two fields, Account_ID and Group_ID, both of which make up the primary key. When the caBuilder tries to generate the class, it crashes when trying to write the _CA_DMLCode method.
>
>During Cr8_DMLCode(), since the only two fields in the table both end up being in the excluded list (henced looped over), the first parts of lcInsert and lcUpdate never get created which results in orphaned ENDTEXT blocks:
>
>#DEFINE VFP_CRLF CHR(13) + CHR(10)
>
>LOCAL lcInsertCmd, lcUpdateCmd, lcDeleteCmd, lcSchema
>
>TEXT TO lcSchema NOSHOW PRETEXT 2
>	ACCOUNT_ID I,
>	GROUP_ID I
>ENDTEXT
>lcSchema = STRTRAN(lcSchema, VFP_CRLF, [ ])
>
>)
>)
>ENDTEXT
>lcInsertCmd = STRTRAN(lcInsertCmd, VFP_CRLF, [ ])
>
>
>	where ACCOUNT_ID = ?crsSecurity_user_group.ACCOUNT_ID AND GROUP_ID = ?crsSecurity_user_group.GROUP_ID
>ENDTEXT
>lcUpdateCmd = STRTRAN(lcUpdateCmd, VFP_CRLF, [ ])
>
>TEXT TO lcDeleteCmd NOSHOW PRETEXT 2
>	delete from security_user_group
>	where
>	ACCOUNT_ID = ?crsSecurity_user_group.ACCOUNT_ID AND GROUP_ID = ?crsSecurity_user_group.GROUP_ID
>ENDTEXT
>lcDeleteCmd = STRTRAN(lcDeleteCmd, VFP_CRLF, [ ])
>
>WITH THIS
>	._BuildSelectCmd()
>	.DeleteCmd = lcDeleteCmd
>	.InsertCmd = lcInsertCmd
>	.UpdateCmd = lcUpdateCmd
>	.CursorSchema = lcSchema
>ENDWITH
>
>
>
>Could you put this on the caBuilder wish list? :)
>
>Thanks,
>
>- Brian
Mark McCasland
Midlothian, TX USA
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform