Hello,
I have a SQL Server 2008 database with 2 tables. These tables are defined like this:
Device
------
ID
Name
Description
TotalApplications
Application
-----------
ID
Name
DeviceID
I recently added the "TotalApplications" column in an effort to speed up a query that is taking WAY too long. The number of applications associated with a device will not change very often. When it does, I will need to write a trigger to handle this. But for now, I just need to populate my database.
Currently, the TotalApplications associated with each device is 0. Clearly I need to update this value for all of my device records. However, I cannot figure out how to do this. Can someone please explain how I can update the TotalApplications value for my Device records?
Thank you SO much for your help!