Which one is bigger (takes more disk space) - view or table?

Questions about the MySQL, PostgreSQL, and most other databases, as well as using it with PHP can be asked here.

Moderator: General Moderators

Post Reply
siskokid
Forum Newbie
Posts: 9
Joined: Mon Jun 25, 2007 2:10 am

Which one is bigger (takes more disk space) - view or table?

Post by siskokid »

Good afternoon,

I have the following question (it might seem silly, but it is important to have it straight) - which one takes more disk space a saved view in a SQL SERVER database (sql query that will woutput columns and rows) or a table itself stored in a SQL SERVER database that contains the same rows and columns as the view? The thing is that the data in the table and the view is stored actually in other tables where I use a many-to-many relation.

I will also very much appreciate an answer which states the exact difference in disk space :)

Thank you in advance,
siskokid
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

Why not test them and find out?
User avatar
ReverendDexter
Forum Contributor
Posts: 193
Joined: Tue May 29, 2007 1:26 pm
Location: Chico, CA

Re: Which one is bigger (takes more disk space) - view or ta

Post by ReverendDexter »

I agree with Feyd on this, you should test and find out, I think it will also help you to look up exactly what differentiates a "table" from a "veiw". With that knowledge, I think you'll find your answer.
siskokid wrote:I will also very much appreciate an answer which states the exact difference in disk space :)
Not possible unless you want to give us all of your data :twisted:
Post Reply