Friday, May 14, 2010

Using sample databases with SQL Server 2008 R2 Nov-CTP

Often times you may want to test something simple and you don’t want to create a database of your own. You can use Microsoft relational database samples. These samples are available for most versions. Recently samples are not bundled with the servers and you may have to get them from online sources.

After downloading the samples you must attach them to the SQL Server as these are Data and Log files. This article shows you the steps involved for attaching a Northwind database to SQL Server 2008 R2 Nov-CTP, but the procedure is the same for other versions as well. Additionally you can also use sp_attach_db and sp_detach_db stored procedures to attach/detach the databases.

Note: Download the SQL Server 2000 Sample DBS as well as Microsoft Sample Databases from the CodePlex site here:


http://sqlserversamples.codeplex.com/#databases


For SQL 2005 (top right of the URL) and SQL Server 2008 R2 databases you go to this URL:


http://msftdbprodsamples.codeplex.com/releases/view/37109

Attaching a Northwind Database to SQL Server 2008 R2

We will attach a Northwind database from SQL Server 2000 samples to the SQL Server 2008 R2 Nov-CTP


Download the SQL Server 2000 Northwind and Pubs databases ZIP file [SQL2000.Sample.Databases.(Northwind,pubs) zip file, 1.202MB]

http://code.msdn.microsoft.com/northwind/Release/ProjectReleases.aspx?ReleaseId=1401

Unzip to a folder of your choice.

Folder structure is shown here:








Right click databases node in SQL Server 2008 R2 Nov-CTP's SSMS (SQL Server Management Studio) to display the following:


When you choose attach drop-down menu by clicking the menu item you will display the following


Click Add… in the top of the window and it will take you to the default location of your database files as shown.


If you did not unzip the files to this location you can also browse folders on your machine to locate them as shown.


Now click on Northwnd.mdf to highlight it and click OK

This brings in both the mdf [data]and ldf [log] files to the Attach windows as shown.

Click OK and after processing your request, Northwind database will appear in your server as shown.


For moving data from SQL Server 2000 to 2005 read this popular article here [0.5 million page views]

Tuesday, May 11, 2010

phpBB brings interoperability with SQL Servers on Windows OS

One of the bastions of LAMP has arrived at Windows OS with full regalia . This highlights two facts, firstly Microsoft's increasing willingness to accept PHP despite the rich flora and fauna of .NET technology; secondly the world got that much larger with ability to fork out in other directions. It is not just because Microsoft is nice, but because PHP user-base is large and sky is the limit for the cloud. Most importantly it is free.

There are a number of databases including SQL Server 2000 and abvee that this driver can configure connections. The list of databases that is supported is in the read me file.
Where to get phpBB3?
It may be downloaded from here.[http://www.phpbb.com/]

Installation basic steps:
1. Unpack the zip file and place it in the root directory of your web server or a directory accessible by the web server. In my case (Windows 7), I have used C:\inetpub\wwwroot. Make sure you make the config.php altered to have write permission.

2. After you have done this, assuming your IIS7 is working, browse to the index.php in the web folder from within the IIS 7 console as shown.





 
 
 
 
 
 
 
 
 
 
 
 
 
 

 

You should see the following web page:



 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
Now click on Install button and on the displayed page click Proceed to next. In the displayed page scroll down on the right to see if you have a game waiting. Looks like I have both MySQl and SQLServers. Actually I have at least 3 or 4 SQL Servers on this machine. Too bad it did not recognisze by SQL Anywhere server.
 

Well you can also use an ODBC connection.
I believe this can connect to SQL Azure on Windows Azure as well.

Sunday, May 9, 2010

This blog is mostly about Microsoft SQL Servers

Welcome SQL Server users

I have been writing about MS SQL Servers for several years and I will be posting exclusively about SQL Servers to this blog. I will be providing links to my SQL Server articles past and present from time to time. Of course that includes SQL Server BI as well as SQL Azure.

Here is a recent article that appeard on the SSWUG.Org site that you may be interested. This is about some observations regarding installing the latest version of SQL Server 2008 on Windows 7.

http://www.sswug.org/articles/viewarticle.aspx?id=48766

I am not paying this invoice. I am disregarding it, becuase....

 I am not paying this invoice because MICROSOFT has not provided me with a satisfactory way to access my account since June of this year des...