I have to create a view from more than one table in an MS SQL Server database, but I am not able to get the correct syntax for the same.
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You’ll have to provide more information about how you are looking to return data from more than one table. Typically you use JOINs:
…where
fkstands for “Foreign Key”, andpkstands for “Primary Key” – assuming these constraints are in place. Maybe you need to use a Cross join instead? Here’s a great visual representation of JOINs visually.Reference: