5

I have added a localdb to my project and trying to add tables to it. But I could not see 'Add Table' item on the menu, there are only 'Refresh' and 'Properties' items. According to the Microsoft SSDT is coming preloaded with VS2015, but there is no option to add a new table. Am I missing something?

enter image description here

4
  • 1
    run a repair via control panel & try rebooting the system ..let me know result Commented Jul 6, 2015 at 9:03
  • @utility, thanks. I am trying but it seems it will take a long time. Commented Jul 6, 2015 at 9:15
  • @utility. It is working now. Thanks. I think you should write it as an answer not comment. Commented Jul 6, 2015 at 11:57
  • thank you @Osman for writing back! great feeling Commented Jul 6, 2015 at 12:06

3 Answers 3

6

Instead of using "Server Explorer", use "View-->SQL Server Object Explorer".

Alternatively you could create an SSDT project, add your tables to the project and then deploy, that would be the correct way to do it! Ed

Sign up to request clarification or add additional context in comments.

4 Comments

Did you mean SSDT project or SQL Server Database Project since I could not find SSDT project but there is a SQL Server Database Project item
Yes sorry it was just me being lazy a "SQL Server Database Project" is SSDT
If I create "SQL Server Database Project" it locates mdf file to "C:\Users\osman\AppData\Local\Microsoft\VisualStudio\SSDT\CodePlus\Database1.ldf" file path. But I want my .mdf file near my .exe. I mean I am devoping like portable. So adding locald is more appropriate this time. Thanks.
THE SQL Server database project lets you create .sql files with your table definitions (there are ui's to help) - you then build a .dacpac and use that to create a database when you deploy, localdb is just for testing on your machine
3

I have added a localdb to my project and trying to add tables to it. But I could not see 'Add Table' item on the menu, there are only 'Refresh' and 'Properties' items.

To resolve the issue :

Go to Control Panel and try repair the software.

Do not forget to reboot the machine .

Comments

2

Even tough I did the repair and rebooted, still I would not get "Add New Table" I verified that the installation (change, modify) had "Microsoft SQL Server Data Tools" selected.

I solved the issue by installing the latest version of "Microsoft SQL Server Data Tools" separately. https://msdn.microsoft.com/en-us/library/mt204009.aspx • Download SSDT Product Release for Visual Studio 2012 (link) I installed the package and rebooted the computer. I opened the project, and I was able to select "Add New Table" :-)

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.