NILKAMAL


hi!

please help me out for this problem

is it possible scan image from scanner for perticular size cos when i scan it scan blank space too

and also in my table have like 10 field with id is primary key but i need one field no duplicate (e.g if driver Lic # i need unique no , no duplicate )

thanks




Re: unique

dni


It may be possible, depending on your software used to scan...

You may index table by id (depending on vfp version):

index on id tag YourTagName of YourIndexFileName ascending UNIQUE







Re: unique

NILKAMAL

thanks for your reply

i am using vfp 8.0

can u tell me where i have to put

index on id tag dl#

in main prg or form load






Re: unique

dni

If you like to (re-)index each time when you start program you may insert it in main (if is before load). When you use table you may use SET ORDER TO YourTagName.






Re: unique

Markish

Hi,

Creating a Unique index will store the matching index key only for the first record that matches the specified index expression in the idx / cdx file. The duplicate entries for the index file are not stored in the index file. Hence even having a unique index will not enforce the uniqueness of the 'Driver licence #' (in your table).

I suppose you have to validate your entries through code only and make sure you don't duplicate the "Licence #" in the table. (If you have the 'id' as the PK)

Best regards,

Markish






Re: unique

Alex Feldstein

NILKAMAL wrote:

in my table have like 10 field with id is primary key but i need one field no duplicate (e.g if driver Lic # i need unique no , no duplicate )

Don't use old XBase style UNIQUE indices. That is not the correct solution.

What you want is an index that works like a Primary Key but you can only have one Primary. What you need then are CANDIDATE indices.

See:

http://msdn2.microsoft.com/en-us/library/yey80zw6(VS.80).aspx

http://msdn2.microsoft.com/en-us/library/f9w73shy(VS.80).aspx

http://msdn2.microsoft.com/en-us/library/9x4e2b05(VS.80).aspx