Search...
FAQs
Subscribe
Pie
FAQs
Recent topics
Flagged topics
Hot topics
Best topics
Search...
Search within JDBC and Relational Databases
Search Coderanch
Advance search
Google search
Register / Login
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
Forum:
JDBC and Relational Databases
Adding columns for all the tables in DB
Thyagarajan Ramanujam
Greenhorn
Posts: 25
posted 15 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
Hi All,
I want to add a new column named version with initial value 0 for all the tables present in a database. What can be done to do this?
Any help is appreciated.
vanlalhmangaiha khiangte
Ranch Hand
Posts: 170
posted 15 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
You can write the sql code :
alter table tablename add version integer default 0;
Hope this helps ..
Paul Sturrock
Bartender
Posts: 10336
I like...
posted 15 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
... and you can generate this script based on the database catalog. What database are you using?
JavaRanch FAQ
HowToAskQuestionsOnJavaRanch
reply
reply
Bookmark Topic
Watch Topic
New Topic
Boost this thread!
Similar Threads
I have fresh new 80 tables in DB, but with no data. Any utility to populate dummy data in all table
SQL command to show tables
Row level lock in Hibernate
getPrimaryKeys() method of DatabaseMetaData
sql doubt
More...