Richard Szalay

Thursday, February 28, 2008

FTP for IIIS7 RTM

The replacement for the FTP service in IIS 7 that I mentioned recently has just been released. Click through to download in x86 or x64.

Labels: ,

Tuesday, February 26, 2008

SQL 2005 XML DML cannot make multiple changes to the same value

With the advent of xml columns in SQL 2005, I was looking forward to the data manipulation that XML Data Manipulation Language (DML) provides.

Unfortunately, it appears that the implementation is horribly limited in that it cannot make an arbitrary number of modifications to the same value in a single update. Take the example below, where we attempt to insert one node for every value in @IntData (3 total) into the xml column of our first row in @XmlData.

DECLARE @XmlData TABLE (ID INT NOT NULL, Data XML NOT NULL)
INSERT INTO @XmlData (ID, Data) VALUES (1, '')

DECLARE @IntData TABLE (ID INT NOT NULL)
INSERT INTO @IntData (ID) VALUES(2)
INSERT INTO @IntData (ID) VALUES(4)
INSERT INTO @IntData (ID) VALUES(6)

SELECT XD.Data, INTD.ID
FROM @XmlData XD
CROSS JOIN @IntData INTD

UPDATE XD SET Data.modify('
 insert <Node value="{sql:column("INTD.ID")}" />
 as last into /
 ')
FROM @XmlData XD
CROSS JOIN @IntData INTD
WHERE XD.ID = 1

SELECT Data FROM @XmlData

As you can see from the output, the cross join returns 3 records but the update only inserts one node. The only way around this is to use a cursor, which is a shame. Here's hoping that they fix that up in SQL 2008.

Labels: ,

Tuesday, February 19, 2008

Toshiba Announces Discontinuation of HD DVD Businesses

Toshiba has officially discontinued the HD DVD business, resulting in the end of the format war that was helping nobody.

Although this comes as no surprise to anyone, I've always preferred HD-DVD as a format. Oh well, no use being sour grapes; at least we are down to only one format.

IIS 7 FTP Publishing Service

The replacement for the FTP service in IIS 7 is almost here, and it's looking better everyday.

Although still only a release candidate (RC0), the new service supports a myriad of new features:

  • FTP over SSL
  • Membership Providers
  • UTF8
  • IPv6
  • (Significantly better) User folder isolation
  • Hostname support (ie. multiple sites on the same port)

The FTP service can also be added as a module to a website, logically binding a website to its FTP site.

In addition, FTP also brings the IIS Managers Service to the table. The IIS Managers Service is basically an IIS specific membership provider that allows creation of users with access to modify an IIS Website or upload to an FTP but without having a windows user counterpart (which means they can't log in to the machine.

I for one am looking forward to the day when IIS7 is commonplace amongst hosting companies.

Labels: ,

Monday, February 18, 2008

Advanced Debugging Lab Series

Over the past few weeks Tess Ferrnandez, an escalation engineer at Microsoft, has been releasing the first of her 10 part series of labs advanced ASP.NET debugging. At the time of writing there are three labs covering Hangs (deadlocks), Crashes, and Memory Leaks.

I really can't recommend these labs enough. Not only do they take you through step by step on how to look at the problems, but each lab asks you questions (eg. "What thread owns the lock?") that are later answered in a review post.

Absolutely top notch quality so far and I am really looking forward to the rest of the series.

Labels: , ,

Microsoft opens the binary formats and starts an open source conversion project

As part of their Open Specification Promise, Microsoft have finally released documentation for their binary office formats (DOC, PPT, XLS). Additionally, they have started an open source project to convert these formats into their respective 2007 package formats.

I've gotta say, this has taken me quite by surprise. I had always assumed that the binary formats would be ignored now that the new model is so easily accessible from code. Just my luck that it comes out about 18 months after I could have really used it.

Stupid word automation.

Labels: ,

My first gripe with Vista

I've been using Vista for quite a while now and I often defend it in the face of naysayers. For example, I am 100% behind Microsoft when it comes to people complaining that their applications don't work in Vista because, frankly, it means the developers of said applications chose not to read the countless documents available on running as least privilege.

It's somewhat fitting, then, that my actual peeve is entirely Microsoft's fault: Despite Windows Vista Home Premium being suitable for web developers (it comes with IIS7, albeit without a kerberos/ntlm authentication module), it seems that the Vista product managers, in their infinite wisdom, decided that the Local Users and Groups MMC snapin was more than the Vista HP user could handle. What's worse, IIS uses an account (IUSR) that I cannot manage (from a group membership perspective) because its not an account that's shown in the control panel sections. Seriously, that's just poor form.

Obviously the APIs are still there, so I wonder if there is an opensource MMC snapin that replicates the functionality out there. If anyone is aware of one, please let me know.

End Rant

Labels: ,