Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to use IDENTITY function
Message
De
14/03/2004 20:11:36
 
 
À
Tous
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Syntaxe SQL
Titre:
How to use IDENTITY function
Divers
Thread ID:
00886170
Message ID:
00886170
Vues:
56
Hello ,everyone!
I use IDENTITY function is Error ,I don,t kown how to use IDENTITY()

This is my code:

use taxi
IF EXISTS(SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES
WHERE TABLE_NAME = 'aa')
DROP TABLE aa
GO

declare @Num as tinyint
select @Num=max(CodeId) from c_mz

select IDENTITY (tinyint,@Num ,1 ) AS id_num, MZ into aa from driverTemp where MZ IS NOT NULL group by MZ order by MZ

go



"Line 5 : '@Num' syntax error
Why IDENTITY Arguments "send" cann't use variable
What's wrong?

Help me ,thanks!
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform