-
connection to MS SQL Server
Chris Johnson Apr 22, 2012 6:15 AM (in response to skleinlercher)Have you been through the tutorials? I'd give them a whirl before starting anything more complicated.
Otherwise to connect to SQL (if set up as odbc)
open the script tab
click connect
choose your odbc and select ok
This will then take you back to the script
Then click the select button and choose your view/Table you want to bring down
#protip - click preceding load and QV will give you the list of field names from the DB which can be useful...
-
connection to MS SQL Server
ericbragas Apr 27, 2012 12:53 PM (in response to Chris Johnson)Which tutorial teaches you how to connect to SQL Server?
-
connection to MS SQL Server
Chris Johnson Apr 28, 2012 12:28 PM (in response to ericbragas)Hi Eric, I've covered this more in my new blog
http://oneqlikatatime.blogspot.co.uk/2012/04/how-to-connect-to-sql-server.html
-
-
-
connection to MS SQL Server
Steve Dark Apr 22, 2012 8:26 AM (in response to skleinlercher)Yes, you can. As Chris says the wizards are quite straight forward to use. To just test a connection though you can use the following code - if your SQL server is on a different box you will need to change localhost to the IP of your server.
Create a new QlikView document, ignore the Excel wizard, save it, select File Menu \ Edit Script, then paste this at the bottom of the script:
OLEDB CONNECT TO [Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=master;Data Source=localhost;Use Procedure for Prepare=1;Auto Translate=True;Packet Size=4096;Use Encryption for Data=False;Tag with column collation when possible=False];
LOAD
*;
SQL SELECT
*
FROM dbo.sysobjects;
Finally, click the Reload button. Obviously the SQL statement can be changed to whatever you like. The connection string assumes a trusted connection, but you can replace this with any valid OLEDB connection string - or use the Connect button and wizard to have QlikView generate the connection string for you.
Hope that helps.
Steve