Best Practices = Database to C# class?
Posted on 2013-11-18
Good Morning experts - I'm working at a steel plant currently and would like to do some analysis on some of the work that is being done - I was trying to create a C# application that will do analysis and then export it into excel or some other reporting "thing"...
For a very simple example lets say my query looks like:
SELECT STUPP_COIL, PO_NUMBER, RUN_DATE, COIL_WEIGHT
WHERE (TO_CHAR(RUN_DATE, 'MM/DD/YYYY') = '11/18/2013') AND (JOB = '9370')
ORDER BY STUPP_COIL
(the job and the date will be entered at the program, not hard coded into the query)
this will pull back about 60-70 "Coils" of steel per day,
If I had a class that had Coil#, po# and RunDate, and weight for the example how would I assign each coil an item in a list (for example) so I could add up all the weights, or see how many coils are being run per day, per hour, etc...
This is a very simplified example so I can hopefully understand the concept - The actual table has about 60 columns in it (I dont need them all, but I figured if I could do it with the bare minimum I could always scale it up)
Could someone point me to the correct direction on what I am trying to do?
I guess I do not know it enought to know exactly WHAT to ask... So, if anyone can help, I would appreciate it.