TSQL - sql server 200 - error syntax
Bonjour,
j'ai un problème que PS sous SQL SERVER 2000, voici le code :
Code:
1 2 3 4 5 6 7 8 9 10 11
|
set dateformat ymd
DECLARE @err INT
DECLARE @SQL_STATEMENT varchar(8000)
begin tran
INSERT INTO IntraqualDev.Intraqual.M83 (CH1) VALUES ('Asep 1 2008 12:00AM')
IF (@@ERROR <> 0) OR (@@ROWCOUNT = 0) PRINT 'ERREUR'
rollback tran |
Résultat affichage :
Code:
1 2 3
|
Serveur : Msg 245, Niveau 16, État 1, Ligne 1
Syntax error converting the varchar value 'Asep 1 2008 12:00AM' to a column of data type int. |
Cependant, je n'arrive pas à récupérer le code error de cette transaction lorsque la syntaxe de la requête n'est pas bonne.
Merci pour votre aide.