if I set length=-1 like this OCIBindByName($stmt,":freq1",&$freq1,-1); freq1 is a char variable nut it's error,this is error message: numeric or value error: character string buffer too small ORA-06512
how to set this parameter
If length is set to -1 OciBindByName will use the length of the current variable to set the maximuum length.
If freq1 is empty the length will be 0 and you'll encounter the message "Numeric or Value error".
Just explicitly set length to the maximum length of your field.
Hth
JBL