auto generate Number
am 08.12.2006 07:14:34 von GHello Firends
I want a sample code for developing an " auto genearte number " and want to
store in database.
Please if you find any code please send
Thanks in Advance
G
Hello Firends
I want a sample code for developing an " auto genearte number " and want to
store in database.
Please if you find any code please send
Thanks in Advance
G
Hi G
This would probably better posted to another group. however I have
found that it is better to allow the database to generate the the
number for you. If using access then try AUTONUMBER, if using oracle
then use a sequence to generate the number Not 100% sure about SQL but
I believe you can us @@Identity.
Reagrds
Tony
G wrote:
> Hello Firends
>
> I want a sample code for developing an " auto genearte number " and want to
> store in database.
>
> Please if you find any code please send
>
> Thanks in Advance
> G
SQL Server has an auto-increment field. @@Identity gets the value of the
identity column of the most recently added record using the same connection.
--
Mike Brind
news:1165701100.541225.214210@n67g2000cwd.googlegroups.com.. .
> Hi G
>
> This would probably better posted to another group. however I have
> found that it is better to allow the database to generate the the
> number for you. If using access then try AUTONUMBER, if using oracle
> then use a sequence to generate the number Not 100% sure about SQL but
> I believe you can us @@Identity.
>
> Reagrds
>
>
> Tony
>
> G wrote:
>
>> Hello Firends
>>
>> I want a sample code for developing an " auto genearte number " and want
>> to
>> store in database.
>>
>> Please if you find any code please send
>>
>> Thanks in Advance
>> G
>