Clear Kerberos Tickets cached on your computer

Having trouble authenticating to that website on the intranet? Try clearing out your cache of Kerberos tickets on your computer. . .
“klist tickets” will list all the tickets you currently have
“klist purge” will clear them out
More information at http://technet.microsoft.com/en-us/library/cc738673.aspx
And you can download the tool at http://www.microsoft.com/downloads/details.aspx?familyid=9d467a69-57ff-4ae7-96ee-b18c4790cffd&displaylang=en

Posted by sweisfeld | with no comments
Filed under:

Shawn @ Tech ED

While I was at Tech ED 2008 in Orlando FL I participated in a roundtable discussion on "How to make community better" with Dan Egan (President of INETA, http://www.ineta.org), Dave Noderer (UG Leader, CO Founder of INETA, http://www.fladotnet.net),  Christine Betts (GM of the Technical Audience Global Marketing for Microsoft) and Mark Wilson (Charlotte Enterprise Dev Guild, http://www.developersguild.org). They thought it was a good idea to record it, so I figured I would share http://mfile.akamai.com/14853/wmv/microsofttec.download.akamai.com/14853/TechEdOnline/Videos/08_NA_DEV_TEOPanel_36_low.asx.

Posted by sweisfeld | with no comments
Filed under: , ,

Virtual CloneDrive

If you have an MSDN license you are flush with lots of ISO files. Maybe you want to burn them all to DVD's but I keep my collection of ISO's on my Windows Home Server (http://en.wikipedia.org/wiki/Windows_Home_Server). This saves me alot of time hunting through the pile of junk on my desk looking for a disc. However it does mean that I need software to mount the ISO. This software adds a virtual DVD drive to your computer allowing you to insert the ISO. The beauty is that it appears just like a normal DVD once mounted. . . The best piece of software I found for the job to date is Virtual CloneDrive from SlySoft (http://www.slysoft.com/en/virtual-clonedrive.html). Happy ISO Busting!

Posted by sweisfeld | with no comments
Filed under:

XML in SQL server

Question From NTSSUG - http://northtexas.sqlpass.org

I am working on an application that has object data mapped to tables. The mapping was done many years ago, before the likes of Hibernate came along. It basically maps a class to a table. Object properties with multiple values get their own tables. There are other interesting mappings, but that's the overall concept.
 
We have a guy that has been doing research on an alternate approach. He's storing the object data in an XML string. The XML string is stored in the only field of a table. The table is the only one in the system. He's reporting huge performance increases with this approach.
 
Have any of you heard of anything like this? What do you see are the pros and cons of such an approach?


Ok, so I come from a little different camp then most on this newsgroup. . . . I am a c# developer, not a DBA. Yes I am the enemy.

"XML String"???? I hope you mean the new XML data type and not a varchar.

However I strongly encourage storing data in a relational format in the database. Querying of XML data is more difficult and less performing then a traditional SQL query. There are XML query options available (http://msdn.microsoft.com/en-us/library/ms345122.aspx). However these require learning new syntax and might not be compatible with all 3rd party tools. (The first time I asked my DBA to create a table with an XML column, DB Artisan the tool they use instead of SQL Server Management Studio puked all over itself, then again it also converted my varchar(max) and varbinary(max) columns into varchar(1) and varbinary(1)).

That being said I do "persist" .NET objects to XML in the database in cases where my only goal is to provide long-term statefullness to my application.

As for space concerns of the XML in the DB, you have a few options (http://msdn.microsoft.com/en-us/library/ms345115.aspx) but "The XML data supplied by a user is stored internally in a binary format" so disk space concerns should be minimal.

As a developer I like XML persistence over Binary. Binary is defiantly faster to serialize and smaller "on the wire", however I think that in most cases the interoperability and human readability of XML outweighs the benefits of binary serialization. (Heck MSFT is using it for Office!)

NOTE your XML documents are limited to 2GB each.

Posted by sweisfeld | with no comments
Filed under:

Fun With TFS

I have been moving to a completely virtural environment for the work I do out of my home. In that process I have set up a VirturalServer with TFS 2008 SP1 and a Dev image with VS Team Suite SP 1. Well I forgot to install the Team Explorer before I installed SP 1 on my dev box, and when I attempted to create a work item I got the following error.

"Could not load type 'Microsoft.TeamFoundation.WorkItemTracking.Client.WorkItemTypeDeniedOrNotExistException' from assembly 'Microsoft.TeamFoundation.WorkItemTracking.Client" exception

I saw a posting on Dan Sniderman's blog saying he had the same problem (http://blog.magenic.com/blogs/daniels/archive/2008/08/24/Fun-with-VS2008SP1-and-VPC.aspx). He said he had to do a complete reinstall to fix the problem. I was not looking forward to that so I tried just reinstalling SP1 for VS 2008 and things appear to be all better now.

Posted by sweisfeld | with no comments
Filed under:

Free .NET Hosting for User Groups

Recently I got a question about free hosting for .NET User Groups

I have compiled a list below. If you know of any more or your company would like to be added to the list  please let me know.

VERIO has hosting for INETA UG members:
http://ineta.mykb.com/Article_7B694.aspx

Discount ASP.NET with Sitefinity CMS (from Telerik)
http://www.discountasp.com/press/2008_05_20_sitefinity-usergroup-hosting.aspx

Applied Innovations with Kentico ASP.NET CMS
http://www.devfish.net/fullblogitemview.aspx?blogid=563
http://www.misfitgeek.com/Trackback.aspx?guid=eb170258-0871-49ed-8ee0-0dd4f2d3df42

 

Posted by sweisfeld | 1 comment(s)
Filed under: ,

Huston TechFest 2008

I will be giving my SQL CLR talk at the Houston TechFest on Saturday September 13 at the University of Houston. It will be a great event.

Posted by sweisfeld | with no comments
Filed under: , ,

UAC in Vista not granular enough?

I had the following chat with one of my coworkers yesterday and I thought I would share. . . What are your thoughts?

BTW: if you have already seen Microsoft’s latest product “Mojave” you have got to check it out! http://www.mojaveexperiment.com/


Mr. Smith [8:19 AM]:
Hey what do you think of this? http://www.vnunet.com/vnunet/news/2183507/vista-secirity-hole-discovered
Weisfeld, Shawn A [8:29 AM]:
I think there is a bigger issue
Weisfeld, Shawn A [8:29 AM]:
so from reading that article the user doesn't like the granularity of UAC
Weisfeld, Shawn A [8:29 AM]:
(i.e. either No access, or full access)
Weisfeld, Shawn A [8:29 AM]:
IMHO a bigger problem is that so many people just turn UAC off entirely
Weisfeld, Shawn A [8:30 AM]:
providing no protection
Mr. Smith [8:30 AM]:
I was just reading about that
Mr. Smith [8:30 AM]:
because people get irritated with clicking 'allow'
Weisfeld, Shawn A [8:30 AM]:
ok people dont want to click "allow"
Weisfeld, Shawn A [8:31 AM]:
and Russinovich wants them not only to allow an installer but pick the correct level of access to give it
Weisfeld, Shawn A [8:31 AM]:
I dont know if this is a technical problem or a people problem
Mr. Smith [8:31 AM]:
good point...
Mr. Smith [8:31 AM]:
but to not even have the ability to restrict the authority of an installer seems like a problem
Weisfeld, Shawn A [8:32 AM]:
ok, so he said he could "do this in XP"
Weisfeld, Shawn A [8:32 AM]:
that means in XP he created an account that did not have admin rights
Mr. Smith [8:32 AM]:
granted, I've never bothered to do it
Weisfeld, Shawn A [8:32 AM]:
and ran his installer as that account
Weisfeld, Shawn A [8:32 AM]:
what is preventing him from doing the very same thing in Vista
Mr. Smith [8:33 AM]:
good question
Weisfeld, Shawn A [8:33 AM]:
if a user only has "user" access, I dont care what UAC popup they click on they cannot give anything admin rights, they dont even have them. . .

 

Posted by sweisfeld | with no comments
Filed under:

The debut of MVP TV August 21st, 2008 | 9:00am – 10:00am (PDT, Redmond time) - Automation with MSBuild 3.5 and Team Build 2008 - by Steve Andrews MVP

All the Interaction of the MSDN Chats but with the richer experience of Live meeting and hosted by the recognized world technology leaders –the Visual Studio Team System Microsoft MVP’s. In this opening session of MVP TV, please join one of the most celebrated and recent Team System MVP Steve Andrews covering off Automation with MSBuild 3.5 and Team Build 2008. Did you know that .csproj and .vbproj files are really MSBuild files?  More than build processes though, MSBuild is a full-featured automation language. It includes structured control flow, variables, refactorability, error handling, logging, and powerful extensibility. You can easily integrate MSBuild into your own enterprise processes and start adding value right away.  We'll also look at how Team Foundation Build extends on MSBuild and adds robust integration with Team Foundation Server. This is one show you will not want to miss!

About Steve Andrews: Steve Andrews has been working as a developer for more than 9 years. During this time, he has designed and developed applications in such widely varying areas as trust accounting, medical information management, supply chain management, and retail systems. He is currently employed at RDA Corporation in Philadelphia, PA, as a Software Engineer and a team member in their Architectural Guidance evangelism team. Steve is also an MCP, ICSOO, Speaker Liaison for the Philly .NET User Group, and all around .NET fanatic.

Thursday, August 21st, 2008 | 9:00am – 10:00am (PDT, Redmond time)

Hosted by MVP Lead Mei Liang, PJ Forgione

Attendee link:
https://www.livemeeting.com/cc/mvp/join?id=WP2PSH&role=attend&pw=4334ml%2BVHT8 

WW event link:
http://msevents.microsoft.com/CUI/WebCastEventDetails.aspx?EventID=1032386225&EventCategory=4&culture=en-US&CountryCode=US

Conf call details:
Toll-free: +1 (866) 500-6738
Toll: +1 (203) 480-8000
Participant code: 6133095

Posted by sweisfeld | with no comments
Filed under:

Allow Remote Connections & Linked Servers

Got the following question via the North Texas SQL Server UG (http://northtexas.sqlpass.org/) mailing list.


Hi,
I am trying to add linked server in SQL Server 2005 (let say server1)for a another remote server(server2) which is also SQL Server 2005. Do I need to create a login on the server2 in order to use from the server1.

Because after creating linked server when I try to query the server2 from server1 getting the following error.

OLE DB provider "SQLNCLI" for linked server "SQL2K" returned message "Login timeout expired".
OLE DB provider "SQLNCLI" for linked server "SQL2K" returned message "An 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.".
Msg 53, Level 16, State 1, Line 0
Named Pipes Provider: Could not open a connection to SQL Server [53].

From the surface area configuration I checked the local and remote connections on server1 and server2.
Is that something I am missing?

Also if some one can give me the T-SQL query to add linked server I would appreciate.


Since I saw that error message yesterday I thought I would blog the link to the instructions on how to enable remote connections on SQL Server.
http://msdn.microsoft.com/en-us/library/ms188279.aspx

To answer the persons question here is the syntax for adding a linked server:
http://msdn.microsoft.com/en-us/library/ms190479.aspx

Happy coding.

Posted by sweisfeld | with no comments
Filed under:

The Top Ten Reasons to Attend the PASS Summit 2008

I read an article on SQL Server Central about the "The Top Ten Reasons to Attend the PASS Summit 2008" (http://www.sqlservercentral.com/articles/SQLServerCentral.com/62979/) and I would like to propose one more. I will let you decide if it is #1, #11 or somewhere in the middle.

If you attend Pass Summit 2008 you will get a chance to see my talk on the SQL CLR!

See you at summit!

PASS Summit
Posted by sweisfeld | with no comments
Filed under:

INETA Champs Program

An XBox or MSDN Subscription to the 10 Most Active Contributors in the User Group Community each quarter.

How?  By doing what you are doing already, you stand to win:
a) Valuable Prizes: An MSDN Subscription.  And, if you already have one, you can choose an XBox instead.

XBoxMSDN Subscription

b) The Fame and Prestige of having an award to hang on your wall that shows that INETA recognizes your contributions to the User Group Community.

Champion Award

c) Official Recognition on the INETA Website  for one year.

All of your peers will be able to see that you stand out above the crowd. If the opportunity presents itself for you to show your dedication to the User Group Community in a public way, there is no better way than to show off your name highlighted on the website of a highly respected organization like INETA.

d) A Badge for your website showing that you are a Community Champion.

When folks visit your website, blog or any other place where you publicly post your work, they will see that you are a Community Champion.

Oooohhhh. Recognition by INETA? Valuable Prizes? An award to hang on my wall? A Badge?  How can I participate?

Well, I am glad that you asked.

INETA has long been known for it's support of User Groups and this year, there are a number of great new programs supporting the User Group Community.  The Community Champs program is one of them.  INETA wants to recognize individuals who are demonstrating their involvement in the User Group community.  The program is aimed at rewarding those that are the most active with the prizes and award mentioned above.  It is INETA's way of recognizing the ones that really bring the community together.  So, in short, if you are the kind of person who helps to run user group meetings, codecamps, or helps out in any number of other ways, you should let INETA know the kind of activities that you are involved in.  If you are very active, you may be recognized by INETA in a very public and spectacular way for the activities that you currently do to help the user group community.

INETA and Community-Credit are making it happen.

Community Credit has been helping to recognize fellow developers for the past number of years for their accomplishments and INETA has been the mainstay of User Groups for many years, so it is no surprise that the two would be working together to make this great program possible.  Best of all, the contributions that you record will also count toward Community Credit prizes, so you may even have a chance to be rewarded with a Geeky, Community Credit prize as an added bonus.

How do I submit my contributions?

Visit the INETA website and go to the Champions section, sign in and let INETA know what you are doing by recording your contributions.  The current quarterly period counts for contributions during period of  June 30th, 2007 to June 30th, 2008.  The final submissions can be made until July 14th.  Keep in mind that the end of this current quarter is coming up pretty soon, so if you have been very active over the last year, be sure to enter them soon so that you don't miss this great opportunity.

What are the benefits of participating?

If you are an individual who is always contributing to the User Group Community, you do it because you like it.  You don't do it because you expect to be rewarded.  At the same time, if you just happen to be rewarded and recognized then that makes it that much better.  Imagine playing on an XBox that you received as a thanks for all of your hard work.  It makes the games just a little bit more fun.  Using your MSDN subscription that you "earned" makes the tools just a little bit better and seeing the award hanging on your wall is a reminder to you and your colleagues just how committed you are.

Can anybody participate?

Unfortunately, the current period (being our first) is for participants in North America only.

Posted by sweisfeld | with no comments
Filed under:

Generics , Extension Methods, and XML Serialization

At the Jax SQL Saturday I was asked to turn a .NET object into an xml file and then reverse the process.

Step 1: Serialization with extension methods
C# 3.0 comes with this cool feature called extension methods. This is syntactical sugar for static methods that allows for you to “add” methods to other objects. To write one of these write a static class with a static method that takes the type you want to extend as the first parameter. The only difference from what you would do normally is to add the keyword “this” before the first parameter. The beauty is that it feels very natural for developers to just type the variable name and press dot and they get your new method in the statement completion in VS. (BTW you can still call the method the way you would in C# 2.0) So with the method below we now have added a Serialize method to Object thus it is inherited everywhere in the entire object model!

public static void Serialize(this object o, string filename)
{
    Type t = o.GetType();
    if (t.IsSerializable)
    {
        XmlSerializer serializer = new XmlSerializer(t);
        using (TextWriter tw = new StreamWriter(filename))
        {
            serializer.Serialize(tw, o);
            tw.Close();
        }
    }
    else
    {
        throw new InvalidOperationException(string.Format("Objects of type {0} are not serializable.", t.Name));
    }
}


Step 2: De-serialization with generics
I like generics for the process of de-serializing, this allows my method to return a strongly typed copy of the object that was serialized to the file.

public static T DeSerializeObject<T>(string filename)
{
    T t;
    XmlSerializer serializer = new XmlSerializer(typeof(T));
    using (TextReader tr = new StreamReader(filename))
    {
        t = (T)serializer.Deserialize(tr);
        tr.Close();
    }
    return t;
}

Use the method like this:
Serializer.DeSerializeObject<Customer>("customer.xml")

Customer c = new Customer { FirstName = "Shawn", LastName = "Weisfeld" };
c.Serialize("customer.xml");

Posted by sweisfeld | 3 comment(s)
Filed under: ,

C# 3.0 (.NET 3.5) Language Features & Delegates

Two more questions from the floor at TechEd.
Perhaps the most frequent question at TechEd is “What are the new features of C# 3.0?” Here is the short list:
• Implicitly typed local variables 
• Extension methods 
• Lambda expressions 
• Object and collection initializers 
• Anonymous types 
• Implicitly typed arrays 
• Query expressions 
• Expression trees 
Check out Anders presentation from last years TechEd here: http://www.microsoft.com/emea/msdn/spotlight/sessionh.aspx?videoid=319
And all the details in this word document:
http://download.microsoft.com/download/5/8/6/5868081c-68aa-40de-9a45-a3803d8134b8/CSharp_3.0_Specification.doc or this URL http://msdn.microsoft.com/en-us/library/bb383815.aspx

Also got a question about what a Delegate was. Here is the definition from the documentation. A delegate is a type that references a method. Once a delegate is assigned a method, it behaves exactly like that method. The delegate method can be invoked like any other method, with parameters and a return value. (http://msdn.microsoft.com/en-us/library/ms173171.aspx)

Posted by sweisfeld | with no comments
Filed under: ,

Silverlight Deep Zoom (aka SeaDragon)

In my second in the series of TechEd Questions I have a good one. Unfortunately it had nothing to do with C#, but that doesn’t diminish its cool factor.

The attendee, lets call her Suzie, volunteered to help organization working with an artist that recently passed away catalogue his work on the internet. She wanted a good way to post high resolution images on the web allowing the public to enjoy this persons artistic contribution. The first thing that jumped to mind with the Hard Rock Demo from Mix (http://memorabilia.hardrock.com) you have got to check this out! You can see the scratches on the guitars. Scott Hanselman has a great blog post with a how to if you want to create your own deep zoom images (http://www.hanselman.com/blog/DeepZoomSeadragonSilverlight2MultiScaleImagesAtMix.aspx). Remember to note that this technology is only as good as the original image so you will need good HighRes images to start with.   

 

Posted by sweisfeld | with no comments
Filed under: ,
More Posts Next page »