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;