|
ing. fabio freddi
wrote:
> I have this
type of problem.
> > Italian linguage use comma for decimal. > With Sap DB standard installation number are stored in database with point > > If I write a select from db with sql studio I have back point > If I use ASP and I write a select from db I have back comma. > Number with comma are not compatible whit standard installation. Numbers are stored neither with comma nor with point
somewhere in the middle.
They have an internal
representation.
What you see is
the character-representation of this number. This may
depend
on some environment-variables
set on your machine.
But, if you are
handling variable do you handle a numeric-value with a
character-variable
which results in
such an error. Why not use an integer, a float or what may
be
ok for this size
of number?
I am not familiar with ASP which may have some
restrictions or the usage of this
environment-variable.
Elke
SAP Labs Berlin
>
> > In this sql in variable TOTI I have back comma and when I write in cgmovt > table I have bach a data type error message > > <% > Set Con = Server.CreateObject( "ADODB.Connection" ) > Con.Open "DSN=serverdb", "test", "test" > > set RS = Server.CreateObject( "ADODB.Recordset" ) > RS.ActiveConnection=con > RS.open "SELECT NUM_MOV,DATA_REG_MOV,COD_CLI_FOR,SUM(IMP_DARE) AS TOT, > SUM(TOT_FAT_AVERE) AS TOTI,SUM(IMPOST_DARE) AS IVA from VCGIVATR > where cau_CONTAB in('101') and esercizio='"&esercizio&"' and > num_mov='"&num_mov&"' GROUP BY NUM_MOV,DATA_REG_MOV,COD_CLI_FOR" > > while not rs.eof > > sqlString = "INSERT INTO CGMOVT (COD_DITTA,"&_ > "ESERCIZIO,"&_ > "PERIODO,"&_ > "COD_GIORNALE,"&_ > "NUM_MOV,"&_ > "CAU_CONTAB,"&_ > "DATA_REG_MOV,"&_ > "NUM_DOC,"&_ > "NUM_DOC_ESTESO,"&_ > "DATA_DOC,"&_ > "COD_CLI_FOR,"&_ > "DESCRIZ_AGG,"&_ > "COD_PAG,"&_ > "COD_BANCA,"&_ > "TOT_FAT_DARE,"&_ > "TOT_FAT_AVERE,"&_ > "DT_INS,"&_ > "CAMBIO,"&_ > "DIVISA,"&_ > "TOT_FAT_D_VAL,"&_ > "TOT_FAT_A_VAL,"&_ > "TIP_DOCUMENTO) VALUES "&_ > "('01',"&_ > "'"&esercizio&"',"&_ > "'"&periodo&"',"&_ > "'"&cod_giornale&"',"&_ > ""&max&"*1,"&_ > "'"&cau_contab&"',"&_ > "'"&DATAR&"',"&_ > "'"&rs("num_mov")&"',"&_ > "'"&rs("num_mov")&"',"&_ > "'"&DATAR&"',"&_ > "'"&rs("COD_CLI_FOR")&"',"&_ > "'"&descriz_agg&"',"&_ > "'"&COD_PAG&"',"&_ > "' ',"&_ > "0,"&_ > "("&rs("TOTI")&"),"&_ > "'"&DATAR&"',"&_ > "1,"&_ > "'EUR',"&_ > "0,"&_ > "("&rs("TOTI")&"),"&_ > "'01')" > Con.Execute( sqlString ) > > rs.movenext > wend > %> > > On Sap DB is possible to to have numbers with comma ??? > > Tanks > Fabio |
- NUMBER FORMAT ing. fabio freddi
- Zabach, Elke
