Here is the code I’m using in the example:
PRINT @set1
PRINT @set2
SET @weight= @set1 / @set2;
PRINT @weight
Here is the result:
47
638
0
I would like to know why it’s returning 0 instead of 0,073667712
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Either declare set1 and set2 as floats instead of integers or cast them to floats as part of the calculation: