texmansru47 Posted October 2, 2008 Share Posted October 2, 2008 I need the ability to package 36 units into one box... each unit will be tracked by that boxID. For example: If I have product in a table with serial numbers 1 thru 36 let's say, and they all go in one box... and that box ID is 3500... how can I: 1) capture that data in the table where the Product ID and the BOX ID are listed 2) only increment the box number to the next number (incremental) when the box is either: A) reached the limit available which is 36 units. B) the user can terminate the packaging BEFORE 36 if there is not enough items to go into the box? c) Need to have the BOX ID auto generated? Honestly I have tried a one thing to no avail. I have tried: $query = "SELECT MAX(`MPBoxNum`) AS `max` FROM `Ship`"; $findings = mysql_query($query) or die(mysql_error()); $row = mysql_fetch_assoc($findings); $startit = $row['max']; // I get a incremental value for each item under box ID (1, then 2, etc). I could have the user insert the BOX ID when they are shipping, but that would be REAL time consuming and a real pain since they would have to know all last BOX ID or run a query to find it. Any ideas? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.