Does creating SQL views of tables slow anything down ?

Using Pervasive SQL 8.6 , and I want to create a SQL view of all my tables that are 2 words (example: "billing detail") . The reason I am forced to do this is because we are dealing with a proprietary database and are programming in VB with Microsoft Access, and we are not able to call on those tables that have 2 (or more) words in the name. The only work around we have figured out is creating views.  Will creating views slow down access on the server at all, will it take up more room on the server ? Are there any hidden down sides in doing this ?

Thanks for any help you can provide !
kasowitzAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

jdlambert1Commented:
A view has the same performance as its underlying query.

For example, if you do a cartesian join on large tables, performance will be at its worst (SELECT * FROM LargeTableA, LargeTableB). If you have a simple select from a single table, with a where clause on a column with high cardinality and an index on that column, performance will be excellent.
chanitoCommented:
1. Have you tried enclosing the name in []? Like

select id, [2word field] from dbo.[2Word Table]

2. Views definitely have a performance impact.  As jdlambert1 says, it highly depends on the query you make.  If possible is better to have the specific queries you want to run in your application as views rather than creating a view of each table like (select * from LargeTable).
RHansonLineaCommented:
A view actually improves performance over a straight SELECT statement.  This is because for a query to execute, the server must plan how it will execute the query.  Each SELECT statement passed must go through this step first, but a view is different.  While it resolves to a SELECT statement, the planning of the statement is done when the VIEW is compiled and does not need to be done again – giving a VIEW a slight performance advantage.  

A VIEW takes no additional space as it merely references the underlying tables, it does not create new data.  If anything, there should be a performance gain, but it may be so slight that it is not really detectable.  It is generally good practice to use VIEWS as opposed to in-stream SELECT statements because of this slight performance gain and the added benefit that a view can be changed at the server without impacting the application using it (as long as the resulting columns are the same).

As far as the use of [ ], this is SQL Server specific and may not apply to Pervasive.  It is my understanding, that in Pervasive you must encapsulate the two-word items in double-quotes (i.e.  "billing detail").  To do this in Visual Basic you may need to use the character codes (i.e. SQL = "Select * from " & chr$(34) & "billing detail" & chr$(34)) to place the quotes in the SQL.

Good luck.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
kasowitzAuthor Commented:
WOW RHansonLinea!  My question was whether all those views would degrade the performance of our server...and you answered the question I have been slaving over...how to do it without views!  You are awesome...thanks.  Check out  
http://www.experts-exchange.com/Databases/MS_Access/Q_21476379.html
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Databases

From novice to tech pro — start learning today.