Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase ««12345»»»

VIEWS 3 Expand / Collapse
Author
Message
Posted Tuesday, March 20, 2012 5:00 AM
SSCommitted

SSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommitted

Group: General Forum Members
Last Login: Tuesday, November 25, 2014 5:11 AM
Points: 1,855, Visits: 508
Thanks for the nice easy question. Had to think about the objects held in the system views, but figured that wasn't what you were testing and where trying to cover with the "space used for the Create Statement" - since you can't create it without populating all the system views!
Post #1269436
Posted Tuesday, March 20, 2012 5:39 AM
SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: 2 days ago @ 1:25 AM
Points: 2,497, Visits: 770
Koen Verbeeck (3/20/2012)
That is the space for the CREATE VIEW statement. That is stored in the sys.sql_modules catalog view. What I'm going after is that extra information is also stored in other catalog views. Not just the CREATE statement.

All mentioned is stored in system catalogs to make views operational and takes minimal space required after create view statement is executed. Catalog views are one form of means to query data from system catalogs.
Post #1269452
Posted Tuesday, March 20, 2012 5:43 AM


SSChampion

SSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampion

Group: General Forum Members
Last Login: Today @ 8:55 AM
Points: 13,570, Visits: 11,383
dawryn (3/20/2012)
Koen Verbeeck (3/20/2012)
That is the space for the CREATE VIEW statement. That is stored in the sys.sql_modules catalog view. What I'm going after is that extra information is also stored in other catalog views. Not just the CREATE statement.

All mentioned is stored in system catalogs to make views operational and takes minimal space required after create view statement is executed. Catalog views are one form of means to query data from system catalogs.


It takes minimal space, but space is space. And it ain't only the CREATE VIEW statement...




How to post forum questions.
Need an answer? No, you need a question.
What’s the deal with Excel & SSIS?

Member of LinkedIn. My blog at LessThanDot.

MCSA SQL Server 2012 - MCSE Business Intelligence
Post #1269454
Posted Tuesday, March 20, 2012 5:50 AM
SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: 2 days ago @ 1:25 AM
Points: 2,497, Visits: 770
Koen Verbeeck (3/20/2012)
It takes minimal space, but space is space. And it ain't only the CREATE VIEW statement...

I agree any metadata takes space, there is no question about it. Everything about database structure is stored in such form and it takes a lot less space than data and indexes.
Post #1269463
Posted Tuesday, March 20, 2012 6:52 AM


SSCommitted

SSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommitted

Group: General Forum Members
Last Login: Friday, November 21, 2014 1:23 PM
Points: 1,951, Visits: 1,473
Great easy question. I think I sat there with the answers already checked for a few minutes thinking to myself, "What's the catch?" and trying to figure out what it was, but there wasn't one.



Everything is awesome!
Post #1269501
Posted Tuesday, March 20, 2012 7:01 AM


Hall of Fame

Hall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of Fame

Group: General Forum Members
Last Login: Tuesday, September 30, 2014 7:42 AM
Points: 3,688, Visits: 72,435
Koen Verbeeck (3/20/2012)
According to CREATE VIEW (Transact-SQL):


When a view is created, information about the view is stored in the following catalog views: sys.views, sys.columns, and sys.sql_expression_dependencies.


Information that is stored in system tables also consumes space...


Yah... I worried when I selected the "correct" answer that this would be used against me.

I was glad that it wasn't but I suspected somebody would say something about it.

some days when I answer these I'm convinced that no matter which answer I pick it will be wrong because it could be argued either way.




--Mark Tassin
MCITP - SQL Server DBA
Proud member of the Anti-RBAR alliance.
For help with Performance click this link
For tips on how to post your problems
Post #1269510
Posted Tuesday, March 20, 2012 7:03 AM
Mr or Mrs. 500

Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500

Group: General Forum Members
Last Login: Today @ 11:54 AM
Points: 568, Visits: 75,500
dawryn (3/20/2012)
Koen Verbeeck (3/20/2012)
That is the space for the CREATE VIEW statement. That is stored in the sys.sql_modules catalog view. What I'm going after is that extra information is also stored in other catalog views. Not just the CREATE statement.

All mentioned is stored in system catalogs to make views operational and takes minimal space required after create view statement is executed. Catalog views are one form of means to query data from system catalogs.



I also agree. Can you CREATE anything without the extra minimal space consumed by the metadata.
Post #1269513
Posted Tuesday, March 20, 2012 7:45 AM


SSCoach

SSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoach

Group: General Forum Members
Last Login: Today @ 9:52 AM
Points: 17,980, Visits: 15,983
Thanks Ron.



Jason AKA CirqueDeSQLeil
I have given a name to my pain...
MCM SQL Server, MVP


SQL RNNR

Posting Performance Based Questions - Gail Shaw
Post #1269551
Posted Tuesday, March 20, 2012 7:53 AM
Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Thursday, January 31, 2013 8:01 AM
Points: 1,228, Visits: 1,046
Great question Bit Bucket. Concise and to the point with a clear answer.
Post #1269561
Posted Tuesday, March 20, 2012 8:18 AM
Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Yesterday @ 10:52 AM
Points: 1,366, Visits: 1,729
Koen Verbeeck (3/20/2012)
According to CREATE VIEW (Transact-SQL):


When a view is created, information about the view is stored in the following catalog views: sys.views, sys.columns, and sys.sql_expression_dependencies.


Information that is stored in system tables also consumes space...


None of those system catalog views are indexed. Which means they aren't materialized. Which means data in them doesn't take up additional space.
Post #1269588
« Prev Topic | Next Topic »

Add to briefcase ««12345»»»

Permissions Expand / Collapse