iizzo Posted August 30, 2003 Share Posted August 30, 2003 Mysql help I need help on a query, I\'m trying to get a report on orders that are new on an issue and orders that where in the older issue but not in the current one ID order_ID issue_number ------------------------------------ 1 1 555 2 1 556 3 2 555 4 1 557 5 2 556 6 2 557 6 1 558 I can\'t get it right Please help I\'m using MySQL 4.0.13 PHP 4.2.3 Link to comment https://forums.phpfreaks.com/topic/964-query-question/ Share on other sites More sharing options...
nysebamse Posted September 1, 2003 Share Posted September 1, 2003 \"SELECT * FROM table_name WHERE issue_number != 555\"; Replace 555 with variable that holds the current issue_number. \"SELECT * FROM table_name WHERE issue_numer != $current_issue\"; Link to comment https://forums.phpfreaks.com/topic/964-query-question/#findComment-3267 Share on other sites More sharing options...
akitchin Posted September 1, 2003 Share Posted September 1, 2003 one minor correction to that second query: \"SELECT * FROM table_name WHERE issue_numer != \'$current_issue\'\"; Link to comment https://forums.phpfreaks.com/topic/964-query-question/#findComment-3278 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.