Jump to content

mysql if statement


Destramic

Recommended Posts

hey guys i have an if statement and if it returns false then i want it to change to variable values....something like this but it doesn't work

 

IF(@points = '0', @rank + 1, @rank @drawing = '1')

 

can anyone tell me how this is possible please

If you're talking about mysql user variables, you need to assign with :=, not =.

Link to comment
https://forums.phpfreaks.com/topic/215704-mysql-if-statement/#findComment-1122974
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.