How do i connect to database after i installed SSIS 2012? - ssis-2012

I am trying to connect to database from Integration Service project from Microsoft visual studio. How do I create a database from SQL SERVER 2012.

SQL Server Management Studio (SSMS) will allow you to create a database and tables through its graphical user interface. However, I'm guessing what you're looking for is actually an SSIS Connection Manager to an existing database. Look at the connection managers in SSIS, create a new one, and fill in the boxes. What you're doing is building a database connection string. You will need credentials (username and password, or a Windows authenticated user) to connect to the database. Also, you may need to spend some time reading the documentation.

Related

Delphi, TAdoConnection, Azure SQL Managed Instance

I'd like to move the database for several Delphi applications from on-premise SQL Server to Azure Managed Instance. It would use Azure Active Directory Integrated authentication.
We use TADOConnections. I'm having trouble setting the connection string. It looks like TADOConnection does not support Azure Managed Instance and Azure Active Directory Integrated authentication. Is that correct?
Version 18.3 and latter of the Microsoft OLE DB Driver for SQL Server includes the required Microsoft Active Directory Authentication Library (ADAL.dll). Since this traffic is going across the internet keeping this up to date would be a good practice.
Then using the connection string shown for the database on Azure as a starting point you can add Provider=MSOLEDBSQL.1 (plus a ; separator if needed) in the ADO connection string so the above driver is used.

TFS database project for both Azure SQL database and on premises with multiple filegroups

I am working on a project to replicate an application that currently runs on premises to an Azure SQL Database. For the foreseeable future, the application will have to run both on site and on Azure. The project is stored in TFS, and multiple filegroups are specified. Development is ongoing. Is there a way I can maintain this as one project in source control, given that Azure SQL databases only have a primary filegroup? I feel like I can't be the first person in this situation, but I haven't found a decent solution yet.
I'm fine with the Azure database only running on primary, but that is not an option for the local database. This is not for a single deployment, I would like to continue to deploy changes both locally and to Azure from source control. I may be asking for too much here, I just really really want to avoid dual maintenance, when there are a number of teams involved.
Thank you!
You have two options:
Add manual SQL Statements to setup Filegroups on your on-premises SQL Server that don't run against SQL Azure
Use a new feature of Azure named SQL Managed Instances. This is fully managed SQL Server instance running in Azure that supports all features of SQL Server such as filegroups. Don't go installing your own SQL Server on IaaS. That's not necessary anymore with this new feature.
There is no way to use multiple filegroups in Azure SQL Database. If you want to move your database to the cloud and keep the ability to use multiple filegroups, please consider setting an Azure VM with SQL Server on it. Another option would be to change your application so that it does not use SQL filegroups.
As for the replication, please consider SQL Server replication or Azure Data Sync. Azure Data Sync requires an Azure SQL database. It is slower than SQL Server replication but it can handle conflicts.

Trying to connect ASP.NET MVC to SQL Server 2008 R2 with possible wrong connection string

Running SQL Server 2008 R2 and ASP.NET MVC 2 web application on the Virtual Server of big german hosting-provider.
I have a problem to connect to the SQL Server.
On localhost this connection string works fine:
#"Data Source=LOCAL-HP;Initial Catalog=OnlineVertrag;Integrated Security=True";
I'm using a similar connection string on the server:
#"Data Source=MYSERVER\SQLEXPRESS;Initial Catalog=OnlineVertrag;Integrated Security=True";
but nothing happens over there.
Here is my project which I am trying to connect: http://www.hotcont.eu/OnlineVertrag/Home
Based on your comments, your SQL instance on the server has a username/password combination. You cannot use the integrated security connection for a SQL Server connection requiring SQL authentication.
Using the login information provided to you by your host, you should update your connection string to the following:
Server=MYSERVER\SQLEXPRESS;Database=OnlineVertrag;User Id=myUsername;
Password=myPassword;
Taken from ConnectionStrings.com
EDIT
Ok - I think I know what you are dealing with now. You have a virutal machine hosted on a large hosting provider -> meaning that you have control over the machine itself (aka Remote Desktop Management or something?)
The SQL connection string that I provided is for use with SQL server accounts -> meaning those that you actually create within SQL server itself. The SQL connection string that you provided uses the current logged in user's user account information from Windows to connect to SQL.
So here is the disconnection between localhost and the virtual server. When you are running on localhost, I am going to assume that you are using the built in web server to Visual Studio or some equivalent. Most often, during debugging, the web application is running under the Logged in user of the machine - aka: you. You have permission to your own SQL database, thus no issue. BUT...when you deploy your web application to an IIS instance, the web application is no longer running as the logged in user, but rather the identity of the application pool that is your app is a member of. Typically this is something like NETWORKSERVICE.
You have three options available to you
Enable and use SQL user accounts for connection from your web application and your SQL server. If you choose to go this route, you will need to use the connection string I provided above.
Login to your SQL server and add the identity of your application pool to the Allowed Users of SQL server and your database.
Change your application pool's identity to an actual user account on the server (BAD IDEA)
Most web applications go with the first option as it allows you do a few things such as create a distinct SQL user for each application that you host and as well as you can explicitly define permissions for the SQL user to each database that it may need access to (for instance, do not allow the SQL user to DROP tables).
EDIT 2
The way you are trying to connect sounds like it should be using the Shared Memory Protocol, but it might be trying to connect over TCP/IP. I forgot this earlier, but most installs of SQL are not setup to listen on the TCP/IP interface on first install. To check your configuration, click the start button (or orb or whatever Microsoft calls that now) -> All Programs -> Microsoft SQL Server 2008 -> Configuration Tools -> SQL Server Configuration Manager. This will open a new window with some options on the left hand side. Click the SQL Server Network Configuration. Ensure that TCP/IP and Shared Memory is set to enabled. If a 64 bit install, you should probably do this for both the SQL Server Network Configuration (32 bit) and the SQL Server Network Configuration
http://msdn.microsoft.com/en-us/library/ms191294.aspx
Try this
Data Source=MYSERVER\SQLEXPRESS;Initial Catalog=OnlineVertrag;Provider=SQLNCLI10;Integrated Security=SSPI;Auto Translate=False
I hope this works for you.

Differences between ADOMD.net and Analysis Services OLE DB Provider (especially regarding authentication)

I'm attempting to connect to a SQL Server Analysis Services cube on a remote server which is not connected to the domain I'm connected to.
I can connect to the cube with Excel after providing username and password. Now I'm trying to connect to the same cube via code.
Unsuccessful connection via AdomdConnection
Using ADOMD.net (AdomdConnection) for SQL Server 2008 R2 I try to connect with this connection string:
Data Source=SRV1;Initial Catalog=Name of Cube;User Id=RemoteAccount;Password=***
This connection fails on the Open method of the connection. Interestingly the "user id" and "password" properties are allowed, because if the syntax was wrong you get a KeyNotFoundException.
Successful connection via OleDbConnection
I can successfully connect if I use OleDbConnection instead and the following connection string (copied from the Excel connection):
Provider=MSOLAP.4;Persist Security Info=True;User ID=SRV1;Password=***;Initial Catalog=Name of Cube;Data Source=SRV1;
So my questions are:
Can someone explain this behaviour? I thought AdomdConnection just used OleDB underneath?
Is there a way to connect to a SSAS
instance with AdomdConnection using
username and password?
Are there any
further differences between
AdomdConnection and OleDbConnection?
All downloads are available here.
I'm using the AdomdConnection succesfully with the username / password keys, but the difference is that I'm connecting to a HTTP data source. The solution I'm using is that I tunnel OLAP traffic over HTTP via IIS 7 as described in MSDN. The user name and password are then impersonated by IIS to Windows credentials.
Note: Disable Anonymous and Windows Authentication in IIS. I only got it working with Basic Authentication. For enhanced security, use SSL.
If you cannot connect the cube with excel, then you cannot connect it with the code.
The difference between ADOMD.Net and OleDb connection is that, the OleDb MSOLAP provider can be used to send MDX, DAX and DMX queries to an Analysis Services database. The result can only be a scalar or a table, so you cannot use an MDX query returning results on more than two axes. When you use a DAX query, the result will always fit well in a table, you can use a DataReader class to get the result.
We prefer mainly ADOMD.NET on OleDb due to the presenceConnection bug which hasn't been resolved.
In order to connect to SSAS instance with ADOMD.NET we need to add the following line in web.config file ( After creation of console application in Visual studio 2012)
Since we will be using Windows authentication to connect to Microsoft Analysis Services 2005, this addition of line in the web.config file is required to impersonate a user having access to the Analysis Services.
We need to configure the IIS server by creating a new application pool.
Following MSDN link will give other parameters of the ADOMD.NET connection String.
https://msdn.microsoft.com/en-us/library/microsoft.analysisservices.adomdclient.adomdconnection.connectionstring

Grails: Using SQL Server 2005 with Grails

We have a requirement where a Grails application is required to connect to an external SQL Server 2005 (i.e. client's database server via a linked server). Our grails application will have its own SQL Server database instance for user authentication (so will mostly have only one domain class) and then it needs to connect to the external SQL Server database to fetch (only SELECT permission provided) data from 10 or 15 tables (out of 250 tables available) and show it the grails application.
I would like to know would be the best approach to take in this scenario.
Thank You.
Jay Chandran.
You can use the http://grails.org/plugin/datasources plugin and configure the external server as a read-only datasource to ensure that only reads are performed. If you don't want to map domain classes on that server you can use groovy.sql.Sql to execute SQL queries.

Resources