• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How Do the Table came into Picture

 
Arun Giridharan
Ranch Hand
Posts: 290
Debian Fedora Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is the data stored in database tables are internally stored as files(the records in the table) and sorted in some tree format internally(like B-tree)
 
Jesper de Jong
Java Cowboy
Saloon Keeper
Posts: 15444
41
Android IntelliJ IDE Java Scala Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That depends totally on the implementation of the database software. There's no reason why database tables would necessarily need to be stored in files (although many database implementations will probably do that). The data has to be stored somewhere, but not necessarily as a file.

By the way, this question sounds like a serious question, so it doesn't belong in the "Meaningless Drivel" forum. I'll move it for you.
 
Arun Giridharan
Ranch Hand
Posts: 290
Debian Fedora Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Jesper de Jong wrote: There's no reason why database tables would necessarily need to be stored in files (although many database implementations will probably do that). The data has to be stored somewhere, but not necessarily as a file.


Than where do the data must be stored(if necessarily not files)
 
Peter Johnson
author
Bartender
Posts: 5852
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Some databases let you set up a raw partition on the disk to store the database data. Whether that raw data can be considered to be files or not is probably up to debate.

Some databases store the data entirely in memory. Most of these allow you to push a copy of the data to a disk file, most do this automatically when the app exits. But an online app running in the cloud might never exit and its database might be distributed and replicated among so many systems that it doesn't ever need to be persisted to a disk drive.

Most database servers that you can install on your desktop store data in files. For example, MySQL places data in various locations depending on which data store mechanism you are using. For example, innodb stores the data for all databases in a single ibdata file; while MyISAM data is stored in a series of file in the mysql_home/data directory (if I recall correctly, one file per table, view and index).
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic