value is -1 i want to take out - sign in a variable how can i do this
If you want to store the "-" (minus) sign in a separate variable, you need to use the substr()
function.
<?php
echo substr('-1', 0, 1); // will result in "-"
?>
These sql useful to you.
select replace(column_name,'-','') from table_name
Eg:- select replace(-1,'-','')
Thank you.