People,Ineedurgenthelp.IhaveajobtodeliverMondayanditonlylacksthatpartofsalesrecord.Itworkslikethis:
Ihaveastockcontrolsystemandsales,whereIregistertheproductsandmakethesales.TheotherpartsarereadythoughI'mbreakingheadonthatpartofrecordingthesalesinthetable.
Followthetable:
Icanfillinallthisdataquietly,butIcannotfindawaytoassociatetheproductssold.Ineededthistogeneratesalesreports.Icouldputthesalescodeinthetable"product" but I work with generic products (I have a line for a product and a column 'qtde') so I can not do it that way.
Please give me a light, I need it urgently!
The following is the database sql: