Note that there are some explanatory texts on larger screens.

plurals
  1. POGetting the difference
    primarykey
    data
    text
    <p>Can you please help me with this?...</p> <p>I have a maintenance table named ticket table and a transaction table called workplan.</p> <p>Ticket table contains <code>tickedID</code>, <code>ticketName</code>, <code>startdate</code>, <code>estimated time of completion</code> and <code>total number of hours</code> columns.</p> <p>And then workplan table has <code>workplanID</code>, <code>ticketID(foreignkey)</code>, <code>currentdate</code> , <code>ticket name</code>, <code>no of hours</code>, and <code>hours remained</code> columns.</p> <p>For instance:</p> <p>I have ticket entry as shown below.</p> <pre><code>ticket ID / ticket name / start date / estimated time of c. /total nb of hours 1 / sample name / 05.21.2013 / 05.23.2013 / 21hours </code></pre> <p>and the next table represents the workplan.</p> <pre><code>workplanID / ticket ID / currentdate / ticket name / no of hours / hours remained 1001 / 1 / may.21.2013 / sample name / 3 / 18 </code></pre> <p>...Workplan ID is autogenerated.</p> <p>If the user manage his/her workplan. The current date will automatically derived. The user will input his/her no of hours.</p> <p>My question is how can i get the difference between the total number of hours from the ticket table and the hours remained in the workplan table?</p> <p>so if the user has managed his workplan again the next day,</p> <pre><code>workplanID / ticket ID / currentdate / ticket name / no of hours / hours remained 1001 / 1 / may.21.2013 / sample name / 3 / 18 1002 / 1 / may.22.2013 / sample name / 4 / 14 </code></pre> <p>Thank you. :D</p> <p>Im using vb.net and sqlserver as my backend.</p> <p>(binding source)</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload