Auto update columns?

Reply

Join Date: Jun 2003
Posts: 313
Reputation: red_evolve is on a distinguished road 
Solved Threads: 0
red_evolve's Avatar
red_evolve red_evolve is offline Offline
Posting Whiz

Auto update columns?

 
0
  #1
Nov 3rd, 2003
Hi! Can anyone please provide me with a little bit of information regarding this subject? I think I've heard from a lecturer that there is a command to auto-update the entries of a table. For example, when a new record is inserted, the salary column would be auto-inserted with (rough_salary - tax_rate) without having the user to key in the salaries. In case, it is trigger you are thinking of, I don't think that is it. Anyone get me? Thanks.
Reply With Quote Quick reply to this message  
Join Date: Feb 2003
Posts: 793
Reputation: Paladine has a spectacular aura about Paladine has a spectacular aura about Paladine has a spectacular aura about 
Solved Threads: 26
Team Colleague
Paladine's Avatar
Paladine Paladine is offline Offline
Master Poster

Re: Auto update columns?

 
0
  #2
Nov 4th, 2003
Well to my knowledge of SQL or Access for that matter. It would be a trigger that does something like that. There is no other way to update a column automatically via a calculation without using a trigger.

So I would be extremely surprised that there is another way. Stored Procedures or Triggers is the only method I know of.

Sorry if that was of no help!
Assistant Manager, Pharmacy Informatics
Wordpress Learning Blog
Updated : ASP.Net Login Code
Reply With Quote Quick reply to this message  
Join Date: Jun 2003
Posts: 313
Reputation: red_evolve is on a distinguished road 
Solved Threads: 0
red_evolve's Avatar
red_evolve red_evolve is offline Offline
Posting Whiz

Re: Auto update columns?

 
0
  #3
Nov 4th, 2003
Umm...thanks a lot anyway. Actually, I am supposed to create a data warehouse. Knowing that data warehouse has all the following characteristics: non-volatile, time variant, integrated, subject-oriented; which is why trigger was not allowed by my lecturer.
Reply With Quote Quick reply to this message  
Join Date: Feb 2003
Posts: 793
Reputation: Paladine has a spectacular aura about Paladine has a spectacular aura about Paladine has a spectacular aura about 
Solved Threads: 26
Team Colleague
Paladine's Avatar
Paladine Paladine is offline Offline
Master Poster

Re: Auto update columns?

 
0
  #4
Nov 4th, 2003
OK...but how does that affect the use of Trigger?

You say time variant (trigger is not), non-volatile (huh?), subject oriented (nothing to do with a trigger). So I am confused as to how else you can do it.

For interest sake, I would love to know...truly love to know, how else you would ever do it.
Assistant Manager, Pharmacy Informatics
Wordpress Learning Blog
Updated : ASP.Net Login Code
Reply With Quote Quick reply to this message  
Join Date: Aug 2003
Posts: 82
Reputation: himerus is an unknown quantity at this point 
Solved Threads: 0
himerus's Avatar
himerus himerus is offline Offline
Junior Poster in Training

Re: Auto update columns?

 
0
  #5
Nov 16th, 2003
My only idea would be to perform your calculations using a web based (PHP, CGI, ASP, etc) script to re-evaluate any fields that may need adjusting due to changing data in another field.

I guess it would all depend on the DB, the interface, and options available. The only ones I've worked with have been SQL systems that are accessable to a web-based script.

As far as a field that is automatically updated by the db itself by simply updating another field... I'm clueless.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC