Ver Mensaje Individual
  #3  
Antiguo 17-07-2021
IVAND IVAND is offline
Miembro
 
Registrado: may 2003
Ubicación: ECUADOR
Posts: 527
Reputación: 22
IVAND Va por buen camino
Gracias mamcx

Debo hacer un proceso para conocer un numero de validacion algo asi esta echo en delphi pero queria ponerlo en el store procedure

Código Delphi [-]
function TDataModule2.cadena11(ail: String): Integer;
Var
  x,largo,suma,total:Integer ;
  uma,weight:Integer ;
  cadena1:String ;
begin
    uma:=0;
    weight:=2;
    suma:=0;
    Largo:=Length(ail);
    for x:=Largo downto 1 do
     Begin
      cadena1:=copy(ail,x,1);
        suma:=suma+StrToInt(Cadena1) * weight ;
        weight:= weight+1 ;
        if weight > 7 Then
            weight:=2;
      End ;
    Total:= (11 - suma mod 11) ;

    if Total = 11 Then
        Result:=0
    Else
    If Total = 10 Then
         Result:=1
    else
         Result:=Total ;
end;
__________________
IVAND
Responder Con Cita