Hello Dimitry,

 

is there no way? I know the thing with the execute statement, but it is not
the best solution. I would like to add a value, if the weekday is 1
(Monday), then I would like to take the variable t1 and add the value from
t1 to the sum..

 

 

Von: firebird-support@yahoogroups.com <firebird-support@yahoogroups.com> 
Gesendet: Mittwoch, 28. August 2019 15:48
An: firebird-support@yahoogroups.com
Betreff: AW: [firebird-support] Array datatype?

 

  

In my case, I would like to do this:

 

create procedure P_ARBZEIT(

beginn date,

ende date,

f1 float,

f2 float,

f3 float,

f4 float,

f5 float,

f6 float,

f0 float)

returns (

azeit double precision)

as

declare variable wt integer;

declare variable akttag date;

begin

azeit = 0;

akttag = beginn;

while (akttag = ende or beginn > ende) do

begin

wt = extract(weekday from :akttag);

azeit = azeit + cast('f'||wt as char(2));

akttag = akttag + 1;

end

 

 

  suspend;

end

 

f1 = Monday, f2 = Tuesday.. f0 = Sunday.

 

I get the day from date with weekday and I would add the value from the day
to the azeit. Take the value from the variable f0 when it is Sunday.

 

My question about the array, because I can set if it is possible
(array[0,8,8,8,8,8,0] and array[weekday])

 

Von: firebird-support@yahoogroups.com
<mailto:firebird-support@yahoogroups.com>  <firebird-support@yahoogroups.com
<mailto:firebird-support@yahoogroups.com> > 
Gesendet: Mittwoch, 28. August 2019 15:29
An: firebird-support@yahoogroups.com
<mailto:firebird-support@yahoogroups.com> 
Betreff: [firebird-support] Array datatype?

 

  

Hello,

 

I have test something like this: 

 

Declare vat integer[7] or {7}.

 

How can I define an array datatype and use it in some functions?
(vat[1]/vat[countervail])

 

Thank you.

 

 



  • [firebir... 'Check_Mail' check_m...@satron.de [firebird-support]
    • AW:... 'Check_Mail' check_m...@satron.de [firebird-support]
      • ... 'Check_Mail' check_m...@satron.de [firebird-support]
        • ... 'Check_Mail' check_m...@satron.de [firebird-support]
        • ... Dimitry Sibiryakov s...@ibphoenix.com [firebird-support]
          • ... 'Check_Mail' check_m...@satron.de [firebird-support]
            • ... Kjell Rilbe kjell.ri...@marknadsinformation.se [firebird-support]
              • ... 'Check_Mail' check_m...@satron.de [firebird-support]
                • ... 'Alan McDonald' a...@meta.com.au [firebird-support]
                • ... 'Check_Mail' check_m...@satron.de [firebird-support]
                • ... 'Alan McDonald' a...@meta.com.au [firebird-support]
                • ... 'Check_Mail' check_m...@satron.de [firebird-support]
      • ... hv...@users.sourceforge.net [firebird-support]

Reply via email to