Tag | SQL Server Posts

If your connection hangs while attempting to start sql server broker service, its likely caused by the system trying to gain exclusive access to your database. Some people recommend stopping and restarting the sql server instance. I find that a little heavy-handed, like swatting a fly with a sledge hammer. Instead switch the database into single user mode, enable the broker service, and restore the database to multi-user mode. 1) Set the database to single user mode: ALTER DATABASE [DBNAME] SET SINGLE_USER ...
This discussion on the printing of Database diagrams is an on-going one. If affects several versions of SQL Server yet microsoft has failed to reproduce it.Please go to the the discussion at http://social.msdn.microsof... There is now an example of this problem posted ...
Step 9: Completing the Database Setup: This step is a very critical step and should performed with very much attention. Below mentioned steps are the ones which I thought were required for the environment I was building but I very highly recommend that you perform this step from the Oracle Installation document which can be found here. Look at Chapter 7 in this document. Updating PeopleTools System Tables: Here PS_HOME is the directory where you have installed your PeopleTools. In our case its C:\PT852 ...
Environment what we are building consists of: Operating System: Windows Server 2008 SP2. Database Server: SQL Server 2008 with SP2. PeopleSoft Application: PeopleSoft Enterprise Human Resources Management System and Campus Solutions 9.0 PeopleTools: PeopleSoft PeopleTools 8.52 Web Server: Oracle Web Logic Server 10.3.4 The machine name given for this environment is WIN2K8 and currently only 1 user, the default username is Administrator and it is the local admin. The below steps are performed with ...
In this article, I will show you some tips to improve your ASP.NET performance. 1. Disable the Debug Mode or Set Debug =”false”How it affect performance: By default this attribute is "true" when you create new application and is useful when you are developing the application. Debug = true means that pdb information to be inserted into file and this results a larger file size and it's performance issue. Before deployment you should set the following tag <compilation defaultLanguage="Vb" debug="false"> ...
The Objective Three of the 6 development teams using TFS are moving to a different network and domain. There is no on-line connection between the old (source) and new (target) networks. The objective was for the teams to come in Monday morning, bring up their development machine on the new network and have everything as it had been on the old network. Failed Approaches Clone the data tier and move the data tier to the new network. This failed because the procedures for moving the hardware to a new ...
This post is an example of how to write a WCF Service using a class. The example uses Visual Studio 2010, written in C#, SQL Server 2008 and hosted in IIS. So lets have at it. The table is pretty simple just three columns, an TestID (int), Value1 (varchar(50)) and Value2 (varchar(50)). The stored procedure used will return one record from the table using the TestID as a parameter. Table SQL: CREATE TABLE [dbo].[Table_1]( [TestID] [int] IDENTITY(1,1) NOT NULL, [Value1] [varchar](50) NOT NULL, [Value2] ...
This is the second post about SQL Azure Federation. In my first post I described a little bit about the theory of data partitioning, included the different between the horizontal partitioning and the vertical partitioning. I also talked about the features need to be done when we implemented the horizontal partitioning. And finally, I described some basic concept about SQL Azure Federation. In this post, I will demonstrate how to use SQL Azure Federation in the SQL Server Management Studio (SSMS). ...
The following procedures describe my approach toward a minimal error prone migration of Microsoft Dynamics CRM 4.0 to MS CRM 2011. 1. I start by installing CRM 2011 with a dummy organisation, yes, I don't import the CRM 4.0 organisation, because I want to make sure CRM 2011 is installed and deployed with out any problems. More over it gives the flexibility to map user, if it is from a different domain. (1,5 Hour) 2. I install all the latest updates and roll-up for the CRM 2011, verify if everything ...
We’ve used dbdeploy.net on a number of projects and have found it to be a useful tool, especially around CI environments. We recently started a Windows Azure project that uses SQL Server and discovered that DbDeploy.Net didn’t work. There have been a few nagging issues with DbDeploy.Net as well, like the lack of support for recursive script directories, and when we looked into the code base, we discovered that it’s not really written to modern software development standards, and that getting it there ...
ASP.NET Enterpise Manager is a web based database management system designed specifically for the management of Microsoft SQL databases through a web browser, without the need for any desktop database management systems such as Microsoft’s SQL Server Management Studio. ASP.NET Enterprise Manager is included as default with an installation of Plesk for Windows, meaning that if you are a customer who uses Plesk based Windows hosting, you will most likely have used ASP.NET Enterprise Manager at least ...
Windows Azure Platform How to Sort Azure Table Store results Chronologically How to upload your Excel and CSV data to the Cloud - Blob Storage SQL Azure Database Notification and Job Scheduling Service for SQL Azure SQL Azure Tutorials – Blog SQL Azure Tutorials - Helping you with Cloud Databases How to build a SQL Server Reporting Services report with SQL Azure? Middleware in the cloud SAP meet Azure Service Bus – EAI/EDI December 2011 CTP Azure Service Bus EAI/EDI December 2011 CTP – New Mapper ...
At several client sites, I have had a problem printing Database diagrams directly from Sql Server Management Studio. The workaround is to right click, copy the diagram and paste into word to print it.If you encounter this, please report the problem at:http://social.msdn.micro... ...
I received the good news on Jan 1st that, for the 4th year in a row, I was awarded a Microsoft MVP award for ASP.NET/IIS. There’s some movement as there always is – some people not getting renewed their MVP award, new people attaining it. Some people have publically voiced how they turned down the award or just didn’t bother working for it for a variety of reasons that I won’t get into here. There’s also been some passionate Twitter discussions around community and groups and how valid they are, ...
I’ve used the platform for ClearQuest migrations to TFS and Subversion migrations to TFS. The setup for testing the configuration can be tricky to ensure you’re starting again from a blank slate. Problem I was puzzled after running a number of test migrations to find that no source code would be migrated for some team projects, but not others. I was starting with a new migration configuration, new destination team project and even a re-install of the platform and the SQL Server DB for the platform. ...
What is the Streetlight Store?The Streetlight Store is a .Net library which uses the Entity Framework and a Microsoft SQL Server database to perform the "back-end" operations required for a typical e-commerce application. While the Streetlight Store is intended to be used for e-commerce, it is "front-end agnostic" meaning that you could just as easily create a point-of-sale user interface.Why is there a Streetlight Store?Why develop another e-commerce solution when there are so many already available? ...
We needed to swap out the DB box. Our DB box runs SQL Server, SSRS and SSAS. The AT is on its own box and SharePoint is on its own box.NOTE: I will update the blog post per resolution of the issue :) The Microsoft procedure I used was: Restore Data to a Different Server or Instance Setup new DB box with WS08 R2 with all updates applied. Installed SQL SQL 2008 R2 on new DB box (same version as on the old DB box). Took TFS offline. Disabled the transaction backup job from existing backup plan (runs ...
This is a strangest error I have come across whilst working with SharePoint 2010, the full error is this. [12/20/2011 5:29:10 PM] Warning: [WSS_Content] The operation did not proceed far enough to allow RESTART. Reissue the statement without the RESTART qualifier. RESTORE DATABASE is terminating abnormally. The error message was written to the file restore.log found in the SharePoint backup folder, it seems that the following keyword in TSQL caused the error. IF EXISTS ( SELECT * FROM master..sysdatabases ...
First off in order to get your asp.net site up and running (without membership) all you have to do is copy your aspx files to the root of the htdocs folder that they supply for you. This in itself is an application directory and because of this you can run ASP.NET pages. For your information, I host my site with HostForLife.euSecond, you can use membership by going to their admin pages, creating a database, exporting your data and schema from your current membership database, and then running a script ...
v\:* {behavior:url(#default#VML);} o\:* {behavior:url(#default#VML);} w\:* {behavior:url(#default#VML);} .shape {behavior:url(#default#VML);} Normal 0 false false false false EN-US X-NONE X-NONE /* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-qformat:yes; mso-style-parent:""; mso-padding-alt:0in 5.4pt 0in 5.4pt; mso-para-margin-top:0in; mso-para-margin-right:0in; ...
Whenever I do use Visual Studio and try to compile something under 64 bit I run into problems. It seems that most MS Devs for Visual Studio and the relevant tool chain are still mainly writing 32 bit applications. Here are some of the latest issues I did run into. COM applications targeting x64 are still using x32 as target platform for the MIDL compiler by default Resolution: You have to select in the UI MIDL – Target Environment X64 by yourself. Alternatively you can edit the vcxproj file directly ...
Our TFS instance had been humming along for some time when I noticed that the full and incremental cube refresh jobs started failing. Using Grant Holiday’s “Team Foundation Server 2010 Administrative Report Pack” I was able to better visualize and diagnose the problem. The Problem The full error message was - OLE DB error: OLE DB or ODBC error: Login timeout expired; HYT00; A network-related or instance-specific error has occurred while establishing a connection to SQL Server. Server is not found ...
Renaming SharePoint service app databases When you install SharePoint 2010 and use the wizards, you will be asked which services you’d like to install. By default all but Lotus-Notes-Connector are preselected. SharePoint will install the services and assign a plethora of databases to serve these services. Alas, horror of horror, all these databases are named by Microsoft and all end with GUIDs. DBAs and other keepers of standards abhor it. Sometimes they even go a step further and want the DB names ...
Here is the official documentation on how to publish a LightSwitch application – How to: Deploy a LightSwitch Application. For this example, I’m going to show how to deploy a simple application that does not have any role-based security set up. I’ll show how we can configure that in a later post. So back over on my LightSwitch development machine the first thing we need to do is specify the type of 3-tier deployment we want. In the case of my application, I want it to be a Windows Desktop client ...
Goal: Rebuild indexes in SQL server. This can be done one at a time or with the example script below to rebuild all index for a specified table or for all tables in a given database. Why? The data in indexes gets fragmented over time. That means that as the index grows, the newly added rows to the index are physically stored in other sections of the allocated database storage space. Kind of like when you load your Christmas shopping into the trunk of your car and it is full you continue to load some ...
SQL Server team has released the new SQL Server Data Tools CTP4. Congratulations and Thanks to Gert Drapers and his team with this great milestone. To lear more about this SSDT CTP4 Release, check: What’s new in SQL Server Data Tools CTP4?http://blogs.msdn.com/... Server Data Tools CTP4 vs. VS2010 Database Projectshttp://blogs.msdn.c... VSDB->SSDT ...
It’s no secret that daylight savings time can wreak havoc on systems that rely heavily on dates. The system I work on is centered around recording dates and times, so naturally my co-workers and I have seen our fair share of date-related bugs. From time to time, however, we come across something that we haven’t seen before. A few weeks ago the following error message started showing up in our logs: “The supplied DateTime represents an invalid time. For example, when the clock is adjusted forward, ...
UPDATED Apr 15th 2013: Corrected to VS2012 Update 2 UPDATED Mar 23rd 2012: Added information about VS 11 UPDATED Mar 21st 2012: Added info and link to VS/TFS 11 tool for getting the Test Attachment Cleaner, now included with the TFS Power Tools UPDATED Mar 17th 2012: Added sql queries for TFS 11 Beta. Changed structure after Adam’s advices. Updated information. UPDATED Jan 9th 2012: Added link to SQL 2008 R2 SP1 CU4 for ghost file fix Background Recently there has been several reports on TFS databases ...
"SQL Server-related performance problems come up regularly and diagnosing and solving them can be difficult and time consuming. Read SQL Server MVP Jonathan Kehayias’ Troubleshooting SQL Server: A Guide for the Accidental DBA for descriptions of the most common issues and practical solutions to fix them quickly and accurately." Please go to http://www.red-gate.com/pro... RedGate produce some superb tools for SQL Server. Jonathan's book is ...
This is the third of a three part series that deals with the issue of faking test data in the context of a legacy app that was built with Microsoft's Entity Framework (EF) on top of an MS SQL Server database – a scenario that can be found very often. Please read the first part for a description of the sample application, a discussion of some general aspects of unit testing in a database context, and of some more specific aspects of the here discussed EF/MSSQL combination. Lately, I wondered how you ...
In this Issue: Brian Noyes, Michael Crump, WindowsPhoneGeek, Erno de Weerd, Jesse Liberty, Derik Whittaker, Sumit Dutta, Asim Sajjad, Dhananjay Kumar, Kunal Chowdhury, and Beth Massi. Above the Fold: Silverlight: "Working with Prism 4 Part 1: Getting Started" Brian Noyes WP7: "Getting Started with the Coding4Fun toolkit Tile Control" WindowsPhoneGeek LightSwitch: "How to Connect to and Diagram your SQL Express Database in Visual Studio LightSwitch" Beth Massi Shoutouts: Michael Palermo's latest Desert ...
Normal 0 false false false MicrosoftInternetExplorer4 /* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-parent:""; mso-padding-alt:0in 5.4pt 0in 5.4pt; mso-para-margin:0in; mso-para-margin-bottom:.000... mso-pagination:widow-orphan; font-size:10.0pt; font-family:"Times New Roman"; mso-ansi-language:#0400; mso-fareast-language:#0400; mso-bidi-language:#0400;} My friend asked me where to ...
This is the second of a three part series that deals with the issue of faking test data in the context of a legacy app that was built with Microsoft's Entity Framework (EF) on top of an MS SQL Server database – a scenario that can be found very often. Please read the first part for a description of the sample application, a discussion of some general aspects of unit testing in a database context, and of some more specific aspects of the here discussed EF/MSSQL combination. Lately, I wondered how ...
For good or bad, Microsoft’s Entity Framework (EF) has become one of the most widely used ORM tools out there. While some may state that it's not among the better ones (or that it's not even a real ORM), it’s definitely the most convenient one: its Visual Studio integration and consequently its integration with the MS SQL Server database is unparalleled. This is especially relevant to people who haven’t used the concept of object-relational mapping before - there's almost no initial learning curve ...
In SQL Server 2008 you can use table valued parameters which can be pretty useful. In the example I use a very simple one to overcome SQL Server’s lack of having a parameter as an array. The example goes through creating the new type, using it in a stored procedure and calling it from an application (VB.Net in this example). You start off with creating the new type. Under Programmability/Types/User-... Table Types create a new table. Here I created a table with a single column to hold an integer. ...
Normal 0 false false false EN-US X-NONE X-NONE /* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-parent:""; mso-padding-alt:0in 5.4pt 0in 5.4pt; mso-para-margin-top:0in; mso-para-margin-right:0in; mso-para-margin-bottom:10.0pt; mso-para-margin-left:0in; line-height:115%; mso-pagination:widow-orphan; font-size:11.0pt; font-family:"Calibri","sans... mso-ascii-font-family:Calibri; ...
If you work with SQL Server you will eventually encounter a JOIN statement. This JOIN statement can be stated as an ordinary JOIN, or as a sub select. In most cases I try to use JOINS (even though it’s just for readability), but in some cases it’s quicker to do it in a sub select (for example with production code, in which you don’t want to change the output but filter output). Curious about the performance differences between the two, I tried to create a test. I created 2 tables with country information: ...
For a full explanation and step-by-step guide to setup a linked server through Sql Management Studio (SMS), check out this reference: http://www.databasejournal.... Here it is in a nutshell: If you are setting up a linked server for another sql server 2005/2008 box, just remember to (1) name the Linked server the same name as its network name, (2) select and provide under the security option ,"Be made ...
On CodePlex there is a new project at http://nsession.codeplex.com for sharing session state between classic ASP and ASP.NET "The objective of this project is to allow ASP Classic to access ASP.NET out-of-process session stores in the same way that ASP.NET accesses them, and thus share the session state with ASP.NET. In the initial release, we only support the ASP.NET state server as it is a popular choice and it offers better performance than the SQL Server session store. Please see the Documentation ...
Once the installer for the AdventureWorks Community Sample Database has finished, we then need to complete the process (not mandatory, but nice to do to play with the OLAP content). The first thing we need to do is make sure we note the location of the script files and samples. The path if you are working with SQL Server 2008 R2 is as follows: “C:\Program Files\Microsoft SQL Server\100\Tools\Samples\Ad... 2008R2 Analysis Services Project\enterprise” I am working with the developer edition, ...
For a while now, if we have been around SQL Server we got used to the different sample databases that were provided. From Pubs to Northwind to AdventureWorks. In order to get the AdventureWorks samples we need to go to CodePlex and download the one that corresponds to the version of SQL Server we are working with. The link to the download site here : http://msftdbprodsamples.co... Now, on to the installation. Once you download the appropriate file, double click and launch ...
In order to refresh your OLAP Cubes (SQL Server Analysis Services), you need to create XMLA files. These XMLA files can be used in a SQL Server Agent Job, so that the Cubes are refreshed and re-processed. To accomplish this, you need to follow the next steps: 1) Deploy your Cube to your SQL Server 2) Right click on the database, and choose “Script database as” –> “Alter To” 3) Add the following node to the top of the XML: <Batch xmlns="http://schemas.micro... ...
SSRS is a wonderful tool for quickly retrieving data from many different data sources and presenting the data to the user at a run-time decided format. One area where SSRS often falls short is when the underlying data needs to come from several different sources. Perhaps we want to retrieve data from the General Ledger which is in Oracle, and join that against a list of departments and employees which are stored in SQL Server for us to display in one table. When this happens, we are unable to join ...
“Because everyone wants to kick their database, but sometimes kicking your database is a good thing!” Many would not argue that you should version your code, and few would argue against versioning your code in a way that can lead back to a specific point in source control history. However, most people don’t really think of doing the same thing with your database. That’s where RoundhousE (RH) comes in. I have been working on RH for over two years now and people always wander what it is, why and what ...
Here I will explain how to get the column names and corresponding datatypes in particular table using SQL Server. Description: I have one table with lot columns in database at that time I tried to know the column names and corresponding datatypes and their maximum sizes in particular table for that I written the following query in SQL server to get column names and datatypes in particular table. USE MySampleDB GO SELECT column_name 'Column Name', data_type 'Data Type', character_maximum_length 'Maximum ...
For (almost) all developers, there’s no greater feeling, then knowing your source code is (relatively) safe. The same counts for T-SQL script. Especially if you know that you need the same code next year (argh). So first thing I did after the initial release of scripts, was looking for a way to check-in T-SQL from SQL Server Management Studio (SSMS). So a colleague of mine, Dries (Blog | Twitter), dropped by with a solution: TFS MSSCCI Provider 2010 from the Visual Studio Gallery. It’s a free plugin ...
BizTalk Server 2010 - Using the WCF-SQL adapter to make multiple stored procedure calls A recent project that I was working on required that I take an incoming flat file, containing multiple transaction records, and load these transactions into a database. Within the source file were multiple instances of any of seven transaction types. The database had a separate table for each transaction type, each with its own stored procedure for inserting a record. So thats seven transaction types and seven ...
If you are planning to deploy your application with SQL CE as your application backend then here are the steps you need to perform. If you’re planning to deploy your application with SQL Server, than please read this post, How to Deploy an ASP.NET MVC 3 App to Web Hosting with "\bin Deployment" I assume that you have your ASP.NET MVC 3 application ready to be deployed with SQL CE 4.0 and EF 4.1. But make sure you have add assembly and for SQL CE 4.0 using NuGet. I recommend you to use NuGet here ...
Last week, at the PASS (Professional Association for SQL Server) Summit in Seattle, Microsoft held a coming out party, not only for SQL Server 2012 (formerly “Denali”), but also for the company’s “Big Data” initiative. Microsoft’s banner headline announcement: it is developing of a version of Apache Hadoop that will run on Windows Server and Windows Azure. Hadoop is the open source implementation of Google’s proprietary MapReduce parallel computation engine and environment, and it's used (quite widely ...
Yesterday, I just posted about How to Fix error: 26 - Error Locating Server/Instance Specified Well, this is an error message that we can find too "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. (provider: SQL Network Interfaces, error: 28 - Server doesn't support requested protocol)" I struggle to find what is the problem. ...