Tutorials

Avoiding File Locks and Cannot Access File Exceptions 

While working through some issues recently with some legacy code writen by someone else I was faced with a horrible case of a shared object that was writing to the file.  This was a "custom" logging implementation and opened a file for append, inserted the line, and then closed the file.  Well in times of heavy load the system would encounter errors such as "Cannot access ___ because it is being used by another process".  So in effect the file was either still open, or the lock was not yet released.  This post goes through a bit of the detail on how I resolved the issue.

Read more...

Posted by Mitchel on Thursday, January 22, 2009

Creating Dynamic Where Clauses with SQL 

One very common scenario in when working with User Interface database queries is the concept of a "Dynamic Search Query". A select statement that can have optional items in the where clause. There are a number of methods to implement this, however, they have varying levels of difficulty and, overall each have their own tradeoffs, in implementation, readability, performance, and accuracy. This article explores a few of the most common methods of doing this.

Read more...

Posted by Mitchel on Friday, January 09, 2009

How I Get My DotNetNuke Sites To Run So Fast 

One of the most common questions that I get via the forums on this site, or via e-mail is "How do you get your sites to run so fast".  Although not perfect, my sites typically run a bit faster than your average DotNetNuke sites.  Previously I have kept the exact specifics of my changes to myself, however, with a litle encouragement from the community I have decided to share the full context of the changes that I make to a default DotNetNuke installation to get better baseline performance, as well as extra items that I do to help when I really need that "boost".

Read more...

Posted by Mitchel on Monday, January 05, 2009

Upgrade to DotNetNuke 5.0.0 From 4.6.2 or Later 

With the upcoming release of the final DotNetNuke 5.0.0 release it is time to get the most current upgrade guide out there.  Upgrading to DotNetNuke 5.0.0 from 4.6.2 or later will be a very simple process thanks to the streamlined upgrade features added in 4.6.2 and later versions of DotNetNuke.  The following instructions provides the steps needed to upgrade to DotNetNuke 5.0.0 frm 4.6.2 or later.

Read more...

Posted by Mitchel on Monday, December 22, 2008

Installing DotNetNuke 5.0.0 On Remote Host 

This is my sixth revision of a DotNetNuke remote hosting provider installation tutorial.  This tutorial will provide you the basic overview of how to perform a clean installation of DotNetNuke 5.0.0 on a remote web hosting provider.  Please note at the time of release only the Release Candidate version of DotNetNuke is available, this version is NOT recommended for production usage.  Please be sure to use the proper version for your intended usage.  This guide will work for both the RC and the final DNN 5.0.0 version.  In the article I will try to point out the most common differences between different hosting providers, I will also be providing specific examples regarding the use of the Plesk control panel which is what my preferred hosting provider (3Essentials) uses.  All steps within this tutorial are promised to work with 3Essentials hosting, others are most likely possible, but have not been fully confirmed with the provider.  Additionally this guide is geared towards a manual instlalation at the root of the site, which is not supported by all hosting providers.

Read more...

Posted by Mitchel on Monday, December 22, 2008

Installing DotNetNuke 5.0.0 Locally 

With the first full release of DotNetNuke 5.0 most likely coming sometime in the very near future I thought it was about time for an update to my standard DotNetNuke installation guides.  This installation guide is geared towards local installation on a Windows XP or Windows Server 2000-2004 server.  Installation on Vista or Server 2008 is slighly different when it comes to the IIS portion of the installation.  This guide is the ninth total revision of my installation tutorials and contains many new updates and recommendations to prevent users from experiencing difficulties when installing.  This tutorial still uses the "Automatic" installation process, this is done to help encourage the creation of a more secured DotNetNuke installation by disabling AutoUpgrade and other features that are not yet configurable via the Installation Wizard.  If enough demand is shown, I can create a tutorial for the installation wizard as well.

Read more...

Posted by Mitchel on Monday, December 22, 2008

Creating a DotNetNuke User Account From Code 

Just recently an issue was brought to my attention that my External Database Provider module when creating users was making it so that notification e-mails could not be sent when assigning roles. So I started looking into the code, and how I was creating a user. The user creation code was something that I have been using for a long time, some code that was first found on a blog or forum post about 2-3 years ago. Not noticing anything wrong with the code, at least from an obvious point of view I started to look into the database to see if there were any differences at the database level. Looking into the users' information I noticed that they were missing their user profile, and then I found out that a few key elements still needed to be set to "fully" create the user. This posting shows you the "Full Code" to insert a user into a DotNetNuke portal from a C# Codebehind, translation into VB should be very simple.

Read more...

Posted by Mitchel on Monday, December 22, 2008

DotNetNuke 4.9.0 Authentication Provider Install Error 

Recently working with a client of mine we discovered a bug in DotNetNuke 4.9.0 that has been reported to the DotNetNuke corporation, but will not be resoled until another relese is completed.  This bug affects the installation of ANY Authentication provider and is only an issue on DotNetNuke 4.9.0 installations.  The bug will manifest its...

Posted by Mitchel on Thursday, November 06, 2008

SQL Server RANK, ROW_NUMBER, and Partition 

Finally getting the opportunity to get back to SQL Server 2005 development, and coming to the conclusion that NOT all of my projects have to support SQL Server 2000 I started looking all of those "fun" new items that we all really wanted. This article is going to go through a scenario that demonstrates how to use Common Table Expressions, Rank() and Partition to get results for a very common data scenario. We will present this information with an introduction to the problem, scripts to setup the problem in a test environment, and lastly the implementation, with a review/summary at the end.

Read more...

Posted by Mitchel on Saturday, November 01, 2008

Limit SQL Server Database List 

Recently when working with a client I was asked how in a SQL Server database environment with multiple databases how we can prevent users from seeing all other databases on the server. Permissions are configured to restrict who can actually query the database, but in the end, individuals still can see the names of the other databases on the server, getting potentially an idea of who else you are hosting, or information that you just don't want to share. I have found many blog articles that talk about how to get around this, but all of them were a bit choppy, so I thought I would take a moment to walk through a demo of the process. This article walks through the entire scenario.

Read more...

Posted by Mitchel on Wednesday, October 15, 2008

Previous Page       2 of 13       Next Page

Content provided in this blog is provided "AS-IS" and the information should be used at your own discretion.  The thoughts and opinions expressed are the personal thoughts of Mitchel Sellers and do not reflect the opinions of his employer.

Friend of RedGate

www.datasprings.com - DotNetNuke Modules ICG Hosting

Click here for advertising information.

Content in this blog is copyright protected.  Re-publishing on other websites is allowed as long as proper credit and backlink to the article is provided.  Any other re-publishing or distribution of this content is prohibited without written permission from Mitchel Sellers.