Kraer, Joseph wrote: <snipped>
I thought that IF statements would do the job, but I get a syntax error (1064). Obviously, they are not the way to go. Nevertheless, here's the complete query so you can get an idea of where I want to go:
Your if statement is wrong. The syntax is: if ( condition, value_if_true, value_if_false ) You can also use 'case' statements: case when condition then value_if_true else value_if_false end Substitute your: - condition - value_if_true - value_if_false into the above syntax. -- Daniel Kasak IT Developer NUS Consulting Group Level 5, 77 Pacific Highway North Sydney, NSW, Australia 2060 T: (+61) 2 9922-7676 / F: (+61) 2 9922 7989 email: [EMAIL PROTECTED] website: http://www.nusconsulting.com.au -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]