IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

MS SQL Server Discussion :

Erreur ETAT E_FAIL


Sujet :

MS SQL Server

Vue hybride

Message précédent Message précédent   Message suivant Message suivant
  1. #1
    Membre averti
    Profil pro
    Inscrit en
    Mai 2002
    Messages
    15
    Détails du profil
    Informations personnelles :
    Localisation : France

    Informations forums :
    Inscription : Mai 2002
    Messages : 15
    Par défaut Erreur ETAT E_FAIL
    Bonjour,

    lorsque je lance une procédure E_FAIL depuis un client 3 tiers .net/vb6 ASP, j'ai une erreur E_FAIL.

    J'ai le MDAC 2.8 sur le Serveur windows 2003, ma procédure renvoie une table de donnée avec champs integer, date, varchar.

    Comment ce problème peut-t-il arriver ?


    Merci.

  2. #2
    Membre averti
    Profil pro
    Inscrit en
    Mai 2002
    Messages
    15
    Détails du profil
    Informations personnelles :
    Localisation : France

    Informations forums :
    Inscription : Mai 2002
    Messages : 15
    Par défaut
    Voici le code de la procédure :

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    100
    101
    102
    103
    104
    105
    106
    107
    108
    109
    110
    111
    112
    113
    114
    115
    116
    117
    118
    119
    120
    121
    122
    123
    124
    125
    126
    127
    128
    129
    130
    131
    132
    133
    134
    135
    136
    137
    138
    139
    140
    141
    142
    143
    144
    145
    146
    147
    148
    149
    150
    151
    152
    153
    154
    155
    156
    157
    158
    159
    160
    161
    162
    163
    164
    165
    166
    167
    168
    169
    170
    171
    172
    173
    174
    175
    176
    177
    178
    179
    180
    181
    182
    183
    184
    185
    186
    187
    188
    189
    190
    191
    192
    193
    194
    195
    196
    197
    198
    199
    200
    201
    202
    203
    204
    205
    206
    207
    208
    209
    210
    211
    212
    213
    214
    215
    216
    217
    218
    219
    220
    221
    222
    223
    224
    225
    226
    227
    228
    229
    230
    231
    232
    233
    234
    235
    236
    237
    238
    239
    240
    241
    242
    243
    244
    245
    246
    247
    248
    249
    250
    251
    252
    253
    254
    255
    256
    257
    258
    259
    260
    261
    262
    263
     
    SET QUOTED_IDENTIFIER OFF 
    GO
    SET ANSI_NULLS ON 
    GO
     
    ALTER     Proc dbo.getBookingDay (
    	@START_DATE datetime  = null,
    	@START_TIME datetime  = null,
    	@END_TIME datetime  = null,
    	@POINT_OF_SALES binary(8) =  null,
    	@TIMEZONE varchar(255)  = null,
    	@GRANULARITY int =  null,
    	@EMPLOYEE binary(8) = null)
    As 
      Begin
     
     
     
     
    DECLARE @SECONDSDELTA int
    DECLARE @GC_START_TIME_SEC int
    DECLARE @GC_END_TIME_SEC int
    declare @gc_calendar_utc_date datetime
     
    print @@ERROR 
     
    DECLARE @MEETING_GRID TABLE (Rn_Appointments_Id_Meet binary(8),                 
            Appt_Date  datetime,
            Start_Time   datetime,
            End_Time   datetime,
            Duration int,
            Activity_Type varchar(20),
            start_time2   datetime,
            end_time2   datetime,
            First_Name varchar(30),
            Last_Name varchar(30),
            CL_Employee_Name varchar(60),
    	Title varchar(10),        
            CL_Morning_Afternoon tinyint,
            class varchar(30),
            Vertical_Position int,
    	description varchar(60),
    	free varchar(5),
            CL_Checked_In tinyint,
            Activity_Complete tinyint, 
            CL_Appt_Status tinyint,
    	Appt_priority tinyint)
    --  CREATE TABLE  #BOOKING_GRID (
     
    print @@ERROR 
     
    DECLARE @BOOKING_GRID TABLE (
            Rn_Appointments_Id binary(8),  
    	Appt_Date   datetime,
            Start_Time2   datetime,
            End_Time2   datetime,               
            Duration int,
            Activity_Type varchar(20),
         	start_time   datetime,
            end_time   datetime,
            First_Name varchar(30),
            Last_Name varchar(30),
            CL_Employee_Name varchar(60),
    	Title varchar(10),        
            CL_Morning_Afternoon tinyint,
            class varchar(30),
            Vertical_Position int,
    	description varchar(60),
    	free varchar(5),
            CL_Checked_In tinyint,
            Activity_Complete tinyint, 
            CL_Appt_Status tinyint,
    	Appt_priority tinyint)
     
     
    print @@ERROR       
     
     
     
    -- If Start_Time and/or End_Time are not supplied, we query the Point_Of_Sales for
    -- default grid values
     
    IF @START_TIME IS Null
    BEGIN
        SET @START_TIME = (SELECT CL_GC_START_TIME FROM Company WHERE Company_Id = @POINT_OF_SALES)
        SET @gc_calendar_utc_date = (SELECT CL_GC_Date  FROM Company WHERE Company_Id = @POINT_OF_SALES)
    END
    IF @END_TIME IS NULL
    BEGIN
        SET @END_TIME = (SELECT CL_GC_END_TIME FROM Company WHERE Company_Id = @POINT_OF_SALES)
    END
    -- Same goes for granularity
    IF @GRANULARITY IS Null
    BEGIN
        SET @GRANULARITY = (SELECT CL_GC_GRANULARITY FROM Company WHERE Company_Id = @POINT_OF_SALES)
        IF @GRANULARITY = 0
    	BEGIN
    	   SET @GRANULARITY = 900
    	END
        IF @GRANULARITY = 1
    	BEGIN
    	   SET @GRANULARITY = 1800
    	END
        IF @GRANULARITY = 2
    	BEGIN
    	   SET @GRANULARITY = 3600
    	END
        IF @GRANULARITY > 2 AND @GRANULARITY < 900
    	BEGIN
    	   SET @GRANULARITY = 1800
    	END
    END
     
    print @@ERROR 
     
    Set @START_DATE = [master].[dbo].[rfn_utctolocaldate](@TIMEZONE, @START_DATE, @START_TIME)
    Set @START_TIME = [master].[dbo].[rfn_utctolocaltime](@TIMEZONE, @gc_calendar_utc_date, @START_TIME)
    Set @END_TIME = [master].[dbo].[rfn_utctolocaltime](@TIMEZONE, @gc_calendar_utc_date, @END_TIME)
    Set @SECONDSDELTA = DateDiff(second, GetDate(), GetUTCDAte())
    Set @GC_START_TIME_SEC = DateDiff(second, '00:00:00.000', @START_TIME)
    Set @GC_END_TIME_SEC = DateDiff(second, '00:00:00.000', @END_TIME)
    --print @GC_START_TIME_SEC
    --print @GRANULARITY
     
    print @@ERROR 
     
    insert into @BOOKING_GRID
    SELECT    
            Rn_Appointments.Rn_Appointments_Id,                 
            Rn_Appointments.Appt_Date,
            Rn_Appointments.Start_Time,
            Rn_Appointments.End_Time,
            Rn_Appointments.Duration,
            Rn_Appointments.Activity_Type,
            cl_Hour.start_time AS Expr1,
            cl_Hour.end_time AS Expr2,
            Employee.First_Name,
            Employee.Last_Name,
            Employee.First_Name + ' ' + Employee.Last_Name as CL_Employee_Name ,
            'Free' as Title,
            employee.CL_Morning_Afternoon,
            dbo.[Cl_fn_generate_style](Rn_Appointments.Activity_Type,Rn_Appointments.Appt_Date,cl_Hour.start_time,Rn_Appointments.Start_Time,Rn_Appointments.CL_Checked_In,Rn_Appointments.Activity_Complete, Rn_Appointments.CL_Appt_Status, getutcdate(),Rn_Appointments.CL_Type_Staff,Rn_Appointments.Appt_priority ) as class,
            dbo.gcfn_vrowposition(DateDiff(second, '00:00:00.000',[master].[dbo].[rfn_utctolocaltime](@TIMEZONE,@START_DATE, cl_hour.start_time)),@GC_START_TIME_SEC, @GRANULARITY) AS 'Vertical_Position',
            Employee.First_Name + ' ' + Employee.Last_Name AS description,
            dbo.cl_Free_Appt(Rn_appointments.activity_type,Rn_Appointments.Rn_Appointments_Id) as free,
            Rn_Appointments.CL_Checked_In,
            Rn_Appointments.Activity_Complete, 
            Rn_Appointments.CL_Appt_Status,
    	Rn_Appointments.Appt_priority
    FROM         Rn_Appointments INNER JOIN
                 Employee ON Rn_Appointments.Rn_Employee_Id = Employee.Employee_Id RIGHT OUTER JOIN
                 cl_Hour ON 
    [master].[dbo].[rfn_utctolocaltime](@TIMEZONE,@START_DATE, Rn_Appointments.Start_Time ) <= 
    [master].[dbo].[rfn_utctolocaltime](@TIMEZONE,@START_DATE, cl_Hour.start_time  ) AND
    [master].[dbo].[rfn_utctolocaltime](@TIMEZONE,@START_DATE,  Rn_Appointments.Start_Time ) < 
    [master].[dbo].[rfn_utctolocaltime](@TIMEZONE,@START_DATE,  cl_Hour.end_time ) AND 
    [master].[dbo].[rfn_utctolocaltime](@TIMEZONE,@START_DATE,   Rn_Appointments.End_Time ) > 
    [master].[dbo].[rfn_utctolocaltime](@TIMEZONE,@START_DATE,   cl_Hour.start_time )
                 WHERE     (Rn_Appointments.Appt_Date = @START_DATE) AND
                 (Rn_Appointments.Activity_Type = 15) and (company = @POINT_OF_SALES and employee.CL_planning = 1 )
     
    print @@ERROR 
     
    insert into @MEETING_GRID
    SELECT     
                 Rn_Appointments.Rn_Appointments_Id,
                 Rn_Appointments.Appt_Date,
        	     Rn_Appointments.Start_Time,
                 Rn_Appointments.End_Time,
                 Rn_Appointments.Duration,
                 Rn_Appointments.Activity_Type,
                 cl_Hour.start_time AS Expr1, 
    	     cl_Hour.end_time AS Expr2, 
                 Employee.First_Name,
                 Employee.Last_Name,
                 Employee.First_Name + ' ' + Employee.Last_Name as CL_Employee_Name ,
     	cast(Rn_Appointments.CL_Treatments_Descriptor as varchar(500))  as Title,
    	employee.CL_Morning_Afternoon,
                 dbo.[Cl_fn_generate_style](Rn_Appointments.Activity_Type,Rn_Appointments.Appt_Date,cl_Hour.start_time,Rn_Appointments.Start_Time,Rn_Appointments.CL_Checked_In,Rn_Appointments.Activity_Complete, 
                 Rn_Appointments.CL_Appt_Status , getutcdate(),Rn_Appointments.CL_Type_Staff,Rn_Appointments.Appt_priority  ) as class,
    	dbo.gcfn_vrowposition(DateDiff(second, '00:00:00.000',[master].[dbo].[rfn_utctolocaltime](@TIMEZONE,@START_DATE, cl_hour.start_time)), @GC_START_TIME_SEC, @GRANULARITY) AS 'Vertical_Position',
           	dbo.CL_Extraire_ApptDescription([master].[dbo].[rfn_utctolocaltime](@TIMEZONE,@START_DATE, Rn_Appointments.Start_Time) ,[master].[dbo].[rfn_utctolocaltime](@TIMEZONE,@START_DATE, cl_hour.end_time)  , @GRANULARITY, ltrim(rtrim(Rn_Appointments.Appt_Description))) AS description,
       	dbo.cl_Free_Appt(Rn_appointments.activity_type,Rn_Appointments.Rn_Appointments_Id) as free,
    	Rn_Appointments.CL_Checked_In,
    	Rn_Appointments.Activity_Complete,
    	Rn_Appointments.CL_Appt_Status,
    	Rn_Appointments.Appt_priority
    FROM  
    	Rn_Appointments INNER JOIN
                 Employee ON Rn_Appointments.Rn_Employee_Id = Employee.Employee_Id 
    	RIGHT OUTER JOIN cl_Hour ON
     
    [master].[dbo].[rfn_utctolocaltime](@TIMEZONE,@START_DATE, Rn_Appointments.Start_Time ) <= 
    [master].[dbo].[rfn_utctolocaltime](@TIMEZONE,@START_DATE, cl_Hour.start_time  ) AND
    [master].[dbo].[rfn_utctolocaltime](@TIMEZONE,@START_DATE,  Rn_Appointments.Start_Time ) < 
    [master].[dbo].[rfn_utctolocaltime](@TIMEZONE,@START_DATE,  cl_Hour.end_time ) AND 
    [master].[dbo].[rfn_utctolocaltime](@TIMEZONE,@START_DATE,   Rn_Appointments.End_Time ) > 
    [master].[dbo].[rfn_utctolocaltime](@TIMEZONE,@START_DATE,   cl_Hour.start_time )
     
    WHERE     
    	(Rn_Appointments.Appt_Date =@START_DATE) and company = @POINT_OF_SALES
    	AND (Rn_Appointments.Activity_Type = 0) and  ((CL_Appt_Status <> 0 and CL_Appt_Status <> 4) or
                 CL_Appt_Status IS NULL ) and 
    	employee.CL_planning = 1 
     
    print @@ERROR 
     
    delete from @BOOKING_GRID 
    from @MEETING_GRID MG, @BOOKING_GRID BG
    where 
    BG.start_time = MG.start_time 
    and BG.end_time = MG.end_time 
    and BG.CL_Employee_Name = MG.CL_Employee_Name
    and Rn_Appointments_Id = BG.Rn_Appointments_Id 
     
     
    print @@ERROR 
     
    insert @BOOKING_GRID
    select * from @MEETING_GRID
     
    print @@ERROR 
     
    select  RN.Rn_Appointments_Id ,                  
            BG.Appt_Date ,
            BG.Start_Time2 ,
            BG.End_Time2 ,
            BG.Duration ,
            BG.Activity_Type ,
            BG.start_time ,
            BG.end_time ,
            BG.First_Name ,
            BG.Last_Name ,
            BG.CL_Employee_Name ,
    	BG.Title ,        
            BG.CL_Morning_Afternoon ,
            BG.class ,
            BG.Vertical_Position ,
    	BG.description ,
    	BG.free ,
            BG.CL_Checked_In ,
            BG.Activity_Complete , 
            BG.CL_Appt_Status ,
    	BG.Appt_priority  from @BOOKING_GRID BG  INNER JOIN Rn_Appointments RN
    ON RN.Rn_Appointments_Id = BG.Rn_Appointments_Id
    ORDER BY BG.CL_Morning_Afternoon,BG.CL_employee_name, BG.start_time, BG.end_time, BG.Activity_Type desc
     
     
     
    /*
    select * from rn_appointments*/
     
    End
     
     
     
     
    GO
    SET QUOTED_IDENTIFIER OFF 
    GO
    SET ANSI_NULLS ON 
    GO

  3. #3
    Membre averti
    Profil pro
    Inscrit en
    Mai 2002
    Messages
    15
    Détails du profil
    Informations personnelles :
    Localisation : France

    Informations forums :
    Inscription : Mai 2002
    Messages : 15
    Par défaut
    L'appel fonctionnait sous vb avec une autre procédure, en mettant celle ci cela ne fonctionne plus.

  4. #4
    Membre averti
    Profil pro
    Inscrit en
    Mai 2002
    Messages
    15
    Détails du profil
    Informations personnelles :
    Localisation : France

    Informations forums :
    Inscription : Mai 2002
    Messages : 15
    Par défaut
    Pas d'idée ? j'ai tout essayé, pourtant cela marchait correctement auparavant et la procédure marche sous l'analyseur de requêtes.

Discussions similaires

  1. Erreur: Etat HTTP 503
    Par lovelace dans le forum Tomcat et TomEE
    Réponses: 7
    Dernier message: 02/04/2008, 11h32
  2. Réponses: 4
    Dernier message: 12/03/2007, 15h25
  3. Tomcat Erreur - ETAT HTTP 500
    Par othmanbenhalima dans le forum Tomcat et TomEE
    Réponses: 1
    Dernier message: 16/11/2006, 12h26
  4. Tomcat - Servlet - Erreur "Etat HTTP 404"
    Par Doumeasse38 dans le forum Tomcat et TomEE
    Réponses: 16
    Dernier message: 03/05/2006, 13h51
  5. [JSP] Erreur Etat de curseur non valide
    Par logica dans le forum Servlets/JSP
    Réponses: 2
    Dernier message: 03/05/2005, 14h42

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo