[DUG] Validating uniqueness in a TDataset

Rohit Gupta r.gupta at xtra.co.nz
Thu Apr 24 13:51:17 NZST 2008


I let it happen and then capture the exception

Simon Garton wrote:
>
> Quick question : how do I validate uniqueness in a TDataset ? I have 
> some data aware controls and a TDBNavigator; I can check other 
> validation stuff in the BeforePost event, but is there a sensible way 
> of testing whether the field ‘name’ (which has a unique constraint in 
> the database) already exists ?
>
> Many thanks,
>
> Simon Garton
>
> GIS/IT Consultant
>
> email : simon at simongarton.co.nz
>
> mob : +64 21 227 4666
>
> lat/long : 36º53'17" S, 174º46'50" E
>
> www : http://www.simongarton.co.nz
>
> http://www.treecapture.co.nz
>
>
>
> __________ Information from ESET NOD32 Antivirus, version of virus 
> signature database 3050 (20080423) __________
>
> The message was checked by ESET NOD32 Antivirus.
>
> http://www.eset.com
> ------------------------------------------------------------------------
>
> _______________________________________________
> NZ Borland Developers Group - Delphi mailing list
> Post: delphi at delphi.org.nz
> Admin: http://delphi.org.nz/mailman/listinfo/delphi
> Unsubscribe: send an email to delphi-request at delphi.org.nz with Subject: unsubscribe
>
>
> __________ Information from ESET NOD32 Antivirus, version of virus signature database 3050 (20080423) __________
>
> The message was checked by ESET NOD32 Antivirus.
>
> http://www.eset.com
>   



More information about the Delphi mailing list