i know this would be probably too much to ask for . i am sorry. and i would really appreciate if someone can guide me in the right direction.
i have made the sales invoice posting form.
the fields are:-
customer id, segment id, date of invoice, invoice no(streamed from mysql max value), items,uom’s prices,quantities.
since the no of items is variable. as in the no of rows changes so i have made it dynamic as per user’s requirement.
i am able to display this data on the next page.
now when i have say 5 itemcodes, their prices and quantities, i want to compare all of these with their corresponding mysql values. for ex. for quantities, i would like to compare the quantities avl in mysql and only then proceed with posting, same is the case with prices. i want to compare the prices with the selling prices listed for those particular items.
i also need help with how to post these arrays to the mysql and then check what all has been posted correctly.
i would greatly appreciate any information,ideas,links, etc. where i can learn or may be if someone can post up a sample code or something.
thanks again.keep smiling 🙂
From what I understand, you are trying to INSERT invoice data after validating from MySQL. A generic answer would:
There are many ways to solve your problem of posting arrays in MySQL, in certain cases, I send client side arrays as CSV strings and use something like PHP-explode(“,” $str) and then insert individual values, however it will differ based on your data-formatting and table design.