• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

update multiple columns at once

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi

Not sure if this is the correct forum to post this but will give it a go.

I am using JDeveloper to create an update page for a table on a database. The end user will only have one update field to update a number in say column A. However there is also another column in my table that should always hold identical information to Column A. Lets call it Column B. How do I get the update on A to automatically update B without having to get the user to have two fields to fill out with identical information. I am using getters and setter methods in a Entity Object.

Can anyone help? Let me know if need to give more info or if there is a more appropriate place to post this

Thanks

Toni
 
Sheriff
Posts: 3837
66
Netbeans IDE Oracle Firefox Browser
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If a table should always keep identical data in column B, why to keep that column in the table at all? It is a strange requirement which probably indicates a less than optimal design somewhere. But if you really need such a setup - two identical columns A and B - you can easily achieve that by only having the column A in the table and creating a view containing all the table's columns plus another instance of column A aliased to "B".
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic