Thursday, June 26, 2008

Problem Connecting to SQL 2005 Named Instance with Vista

If you are running Vista and you are using Management Studio or an application that is connecting to a SQL 2005 named instance server, you will receive the error.

Login timeout expiredAn error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections.SQL Network Interfaces: Error Locating Server/Instance Specified [xFFFFFFFF]. (Microsoft SQL Native Client)
This problem results in that in Vista, you must specify the port number of the instance you are connecting to. So rather than connecting to Server\Instance you need to connect using Server\Instance,port.

Friday, June 20, 2008

Using Access 2007 as a conduit to SharePoint list data

I stumbled onto something today that I don’t know what to think of and thought I would kick it out to the world for comment. I was grappling with the idea of using “data” in lists that exist in a site collection. By using, I mean using in the since of reporting on it, integrating it with other data sources (SQL Server, web services, etc), etc. I knew that Access 2007 had native capability to treat SharePoint lists like a linked table. So, I thought to myself that if I can create a linked table to a SharePoint list and then I can use the Access 2007 database as a data source for applications other (ASP.Net, SSIS, SQL Server, SRS, etc) then would that work. Indeed it did! I first created two custom lists in SharePoint, each of them being in totally different web sites within the same site collection. Then I created an Access 2007 database and created linked tables to these lists. The first test was to see if I could join these lists together in an Access query. Yes. Then I thought, okay, can I create a SQL Server Integration Services (SSIS) package to work “directly” with the SharePoint data, but use the Access database as a conduit. So, I setup a connection to the Access database using the OLE DB Office 12 driver. Then I created a SQL Task to insert into the Access linked table that was linked to one of the lists. I ran the SSIS and by golly it inserted into the list just fine. I then wrote a transformation task that joined SQL Server data in a SQL database to the list data in SharePoint in order to insert data into another SQL Database. And that worked.

So, is this good or bad? I can’t see this being very scaleable, but using Access 2007 as a conduit into SharePoint data is a lot easier than working with the SharePoint API or web services and dealing with CAML. It seems to be that Microsoft should introduce a SharePoint data provider that can be used in SQL Server or .NET so that you can treat SharePoint lists just like tables without all of the headaches. What are your thoughts?

Problem with Site Navigation in SharePoint

When I tried to do something in a site's Navigation, after clicking the OK button, I would get this SharePoint error.

Microsoft.SharePoint.Library.SPRequestInternalClass.MoveNavigationNode

It turns out this is because a Heading somehow has an invalid link. The only way I found to fix this is to go into SharePoint Designer and change to the Navigation pane and delete the offending headings. You can determine the offending heading by clicking on them in the site. If you get a page cannot be displayed error, then you have found the right heading. In SPD delete these. And then you will have to recreate the Navigation for these and their sublinks.

Wednesday, April 30, 2008

Friday, April 25, 2008

Mapping a folder to the GAC

Here is the command to map the GAC folder to a drive

Start->Run->cmd
subst g: c:windowsassembly (with the backslashes in the right spot)

Open G: drive in Explorer

Thursday, April 24, 2008

Weird GAC issue

I was doing a WSS Application Page (first time to do this) and found a weird behavior. When I went to test the page, I would get an "File not found" WSS error. I would go back to my code and review it and make a couple of changes and redeploy it. Then it would work. Then I would make a simple change, redeploy it, and then it would break. It turns out it was a problem with the registering of the assembly into the GAC. It would fail to register every other time. I caught this by mapping a drive to the GAC folder and watching it. When the page would work, the DLL would be copied to the correct folder. But the next time it would be copied to some kind of temp folder. Then if I looked in the VS output window, I would see that it was failing because of access denied when it went to register it. I haven't dug any further into this, but for right now, when I make a change, I just make sure the DLL is put into the GAC correctly before I test it.

Scan directly into SharePoint

I recommended this product to my client. It allows you to directly scan a document from a desktop into SharePoint. It works really well and is easy to setup. And for the price, it isn't a bad deal.

https://www.darkblueduck.com/Default.aspx