It is possible to import a database in dbproject using SSDT. but is there any api or commands available to do the same thing automatically like silent installer.
i have a datawarehouse which depends on OLTP but the OLTP is maintained by other team. i want to create a dbproject for OLTP but the problem is to keep it updated whenever the OLTP changed by other team who are not using this DBProject. is there any way using commandline or any api that the OLTP could be imported to dbproject automatically without SSDT UI?
i searched a lot to do this. and finally came to know that microsoft didnt provide command line to update dbproject from database. vice versa is possible using command line.
i got below text on MSDN
You cannot use VSDBCMD to import objects and settings into a data-tier
application component (DAC) project. You must use the Import DAC or
Import Script commands from within Visual Studio. For more
information, see How to: Import Database Objects from a Script, and
the following pages on the Microsoft Web site.
The Site where i get to know you can not import dbproject from database using commandline/VSDBCMD
finally i did it using codedUI to automate updating of DBProject from Database.
Related
I hope to be able to use SSDT (SQL Server Data Tools) to put our database schema under version control. Importing a database into an SSDT project in Visual Studio creates a nice textual representation of the database schema, suitable for versioning.
Now, the question is, when changes are made to the database schema - how can we programmatically, or from the command line, update (or re-import) the SSDT project?
You can use the built-in schema compare tool to do this, but it seems that you are not developing the way SSDT database projects want you to. It's designed for offline editing, which means you need to first edit the .sql files in your project, and use F5 to deploy to your dev DB for testing.
If you'd prefer to keep working connected, you might want to try SQL Change Automation, a tool we offer here at Redgate. This has a one-click import option that automates the pulling down of database changes to your database project.
SSMA for Access to Console (AccessToSQL)
I created a project with SSMA for Access and successfully imported an Access file to the SQLServernow, I want to automatize the task with SSMA for Access Command Prompt Also I found the documentation to be quite information lacking.
Edit:
With the provided sample XML and some minor tweaks I'm able to migrate the tables, I think my problem is solved.
I think it's because it's trying to migrate the access tabes and queries there is any way to only migrate the tables?
(I should add that migrating only the tables with the SSMA(GUI) works just fine.)
SSMS import Data
I also tried to import the data using the Server Management Studio, but since it's an express edition I'm unable to save the package as described in this process.
Affter fiddling arround for two days I finally managed to make SSMA for Access Command Prompt work by editing the sample script to fit my needs, you can see it here.
Now I'll schedule the task with the Windows built-in scheduler and that should do the trick.
We have an existing SQL Server database, and I'd like to create a Visual Studio database project for it and put some of the scripts for the stored procedures in that database in source control. So, I thought I would create a new database project. Is there a way I can wire up this database project to the database? I thought it might be "Add Database Reference", but that only gives me options to use some other database project in the current solution, not set up the current project to be connected to an actual database.
Ideally, I'd like to be able to right-click on my project and do a "Publish" and have all my database info prefilled. I realize that I might be thinking of this wrong, but searching around on the web is of little help. It is surprising how poorly these concepts are documented.
EDIT: After the first answer, maybe my question really is: How can I have only a part of a database managed in a database project? I had assumed this was an ordinary thing that people did all the time with database projects, but maybe not. In my case, I would like to have only some of the stored procedures in source control.
After further reasearch, it seems the answer is, "no, there is no way" to have only a part of a database managed in a database project.
I'm using vs 2013 but i think this is valid back VS 2008
Right click database project.
Then choose -> import -> database.
Setup a connection to your target database.
When you import select the import setting Folder structure Schema\Object type
And run the wizard.
This builds a folder structure containing sql script for your schema objects.
Alternatively if you have sql data tools you could run the schema compare against a blank project.
I have a Visual Studio 2010 website project that I'm creating a Deployment Package for. My website relies on a SQL database that I also include in the deployment package. Importing the deployed package in IIS on the production server worked great during the first deployment, when there wasn't already a database. For the second+ deployments, I get an error during the import that says there is already an object named such and such. It looks like it's trying to create the database again instead of updating the database schema since the last deployment.
I'm creating the deployment package and copying the zip to the production server and importing directly into IIS via WebDeploy 2.1. How can I just update the database? I tried having a Visual Studio sql database project and having the package include just the generated .sql file from the "Deploy" of that project, but was meet with other un-related problems. It just can't be this difficult. How should I deploy database schema updates?
You'll need to deploy database changes using custom scripts (if you want to preserve data).
Or, if you just want to drop and recreate certain object you can do this using automated scripts.
Either way, it's not as easy as pushing out the original database.
If you dont have database changes you can exclude the database from the deploy (Package/Publish Web tab - untick database).
Please see the following article http://msdn.microsoft.com/en-us/library/dd465343.aspx
Pay special attention to the "Redeploying By Using Automatically Generated Scripts" and "Deploying Database Changes by Using Custom Scripts" sections.
I need to import all the webtrends data to my local sql server database. on top of that i need to build reports.
I am very new to Webtrends, so can some one suggest me how to import the WebTrends data to my local DB Server.
Just for context - I work at Webtrends.
My first questions is are you using the site software version or the ondemand SaaS version? It also depends on which version.
If you're using the latest version of software the best way to go about getting things from the Webtrends Analytics product data store is to use the ODBC connector that is available for the product. This you can download from the web UI and it installs with a single click. I can provide more documentation, just send me an e-mail and I'll send you the actual documentation file on this.
The other method, and this is currently in beta and available only to OnDemand customers is to use the web services (REST based) that we've created. Check out the documentation here: http://product.webtrends.com/dxapi/index.html