Subject Re: [IBDI] Stroed procedure help under interbase 6.0 ..
Author Jacco Hotel Concepts
Hi Fabrice,
 
In the UPDATE and SELECT queries I see no WHERE clauses so I
presume that the tables COMPTEUR and SOCIETE only have one record?
 
Hotel Concepts R&D
Jacco Kulman
Jacco@...
 
WWW.HotelConcepts.COM
Veerdijk 40d
1531 MS  WORMER
The Netherlands
tel: +31-75-621 15 51
fax: +31-75-628 93 64
----- Original Message -----
Sent: woensdag 13 september 2000 10:46
Subject: [IBDI] Stroed procedure help under interbase 6.0 ..


Hello,
 
When I call this stored procedure, the result value CODE is always equal to NULL !
 
CREATE PROCEDURE NEW_CODE_HISTO
RETURNS (CODE VARCHAR(15))
AS
DECLARE VARIABLE TMPCODE VARCHAR(15);
DECLARE VARIABLE TMPSOCIETE VARCHAR(5);
BEGIN
  UPDATE Compteur
       SET Historique = historique + 1;
 
  select cast(Historique as VARCHAR(15)) from compteur
    into  :TMPCODE;
 
  select cast(s_code as VARCHAR(5)) from societe
    into  :TMPSOCIETE;
  CODE=TMPCODE+TMPSOCIETE;
 suspend;
END
 
But "select cast(Historique as VARCHAR(15)) from compteur" always give me a value
and "select cast(s_code as VARCHAR(5)) from societe" always give me a value !
 
Fabrice Vende
fabrice@...
 
-
SARL I N F O C O B
Developpement, formation, matériel, logiciel
http://www.infocob.com
 

   

Community email addresses:
  Post message: IBDI@onelist.com
  Subscribe:    IBDI-subscribe@onelist.com
  Unsubscribe:  IBDI-unsubscribe@onelist.com
  List owner:   IBDI-owner@onelist.com

Shortcut URL to this page:
  http://www.onelist.com/community/IBDI