Please start any new threads on our new 
    site at https://forums.sqlteam.com.  We've got lots of great SQL Server
    experts to answer whatever question you can come up with.
    
        
            
                
                    
                        
                            
                                | Author | 
                                
                                 Topic  | 
                             
                            
                                    | 
                                         the1mills 
                                        Starting Member 
                                         
                                        
                                        1 Post  | 
                                        
                                        
                                            
                                            
                                             Posted - 2011-02-28 : 13:54:38
                                            
  | 
                                             
                                            
                                            | Hey folks:Can anyone tell me what's wrong with this SQL statement, please.The error I get is "Syntax error in CREATE TABLE statement" (even though I am trying to create a VIEW, which is of course, a table by nature, but anyway the CREATE VIEW command should be different than CREATE TABLE, so the error message is a little strange).Here's the code:CREATE VIEW skycareview1 AS   SELECT TOP 4 Resources.Resource_ID_PK, Rating.Rating_Per_Transaction_Type1FROM Resources, Rating, ReferralHistoryWHERE Zip_Code Like '2*' And Resources.Resource_ID_PK=ReferralHistory.Resource_ID And Resources.Resource_ID_PK=Rating.Resource_ID And (State='MD' Or State='DC')ORDER BY Rating_Per_Transaction_Type1 DESCAnyone see what's wrong with it? It works fine without the CREATE VIEW statement.Thanks!AlexAlexander Mills, EIT | 
                                             
                                         
                                     | 
                             
       
                            
                       
                          
                            
                                    | 
                                     SMerrill 
                                    Posting Yak  Master 
                                     
                                    
                                    206 Posts  | 
                                    
                                      
                                        
                                          
                                           
                                            Posted - 2011-04-29 : 20:17:07
                                          
  | 
                                         
                                        
                                          Since this also errors out, it is not a problem with your syntax.CREATE VIEW skycareview1 AS SELECT * FROM resources The best I can find on the web is http://www.pcreview.co.uk/forums/create-view-t1082794.htmlwhich seems to indicate that it can't be done in JET...but you need to read it.http://msdn.microsoft.com/en-us/library/bb221208(v=office.12).aspxThe page above does not contain reference to the text "CREATE VIEW", so error 3290 must have been re-used.~ Shaun MerrillSeattle area  | 
                                         
                                        
                                            | 
                                         
                                       
                                     | 
                                   
                            
                            
                                | 
                                    
                                      
                                     
                                    
                                 | 
                             
                         
                     | 
                 
             
         |