Wise man or Wise guy? You Decide

Just another WordPress.com weblog

Archive for the ‘Bugs’ Category

Office 2007 Pro Plus Installation Issues

Posted by sqlwiseguy on August 10, 2009

Since I have an MSDN subscription I downloaded Windows 7 Ultimate 64-bit this past week.  I installed it on my laptop and then began installing applications.  When I went to install Office 2007 Pro Plus it would start and then hang looking for ProPlsWW.cab.  I attempted the install at least 10 times.  I tried copying the install from the CD to my hard disk, I tried moving PropPlsWW.cab to another location, I tried screaming and yelling at it to “Work you piece of junk!”, but to no avail.  I did look it up on the internet (I am currently using Bing Vs. Google).  The most promising link I found was to delete the 11.0 or 12.0 registry entry under HKLM\Software\Microsoft\Office.  I did try this and it didn’t work.

I finally unpacked the cab file and saw that the files in it seemed to relate to MS Access.  I re-attempted the install, but this time I did not include Access and I went through all the tools installed and deleted any that referred to Access.  I did not write down what I found because I wasn’t planning to blog about it, and not planning on re-installing again!.  Finally at this point Office installed successfully.  I then re-ran setup, added Access, and viola, install complete.

Advertisements

Posted in Bugs, Install, MS Office | Leave a Comment »

The Deception of IsNumeric()

Posted by sqlwiseguy on April 14, 2009

Has anyone else ever used the IsNumeric() function to try to eliminate this error (or similar):

Msg 8114, Level 16, State 5, Line 1
Error converting data type varchar to numeric.

yet still get the error? Isn’t that what the function is for?  Here’s what is says in BOL:

ISNUMERIC returns 1 when the input expression evaluates to a valid numeric data type; otherwise it returns 0

But run this code (generates a list of ASCII Characters):

;WITH cteNumbers AS
   
(
   
SELECT TOP 255
        ROW_NUMBER
() OVER(ORDER BY NAME) AS n
   
FROM
       
sys.all_columns AS AC
   
)
   
SELECT
       
n AS ASCII_code,
       
CHAR(n) AS [character],
       
ISNUMERIC(CHAR(n)) AS is_numeric
   
FROM
       
cteNumbers
   
WHERE
       
n <=255 AND
       
ISNUMERIC(CHAR(n)) = 1

And you’ll see that the first 10 rows and last 8 rows returned are not what I would consider numeric.  Or how about this:

SELECT
   
ISNUMERIC('20,00')
GO
SELECT
   
CONVERT(DECIMAL(9,2), '20,00')

The first statement returns 1, while the second fails. 

Here is the last interesting behavior of IsNumeric() in relation to Cast/Convert provided by Frank Kalis on this SQLServerCentral thread:

SELECT ISNUMERIC(0X0e) AS E, ISNUMERIC(0X0fAS F

E           F          
----------- -----------
0           0

(1 row(s) affected)

WHILE

SELECT CAST(0X0e AS INT) AS E, CAST(0X0f AS INT) AS F

E           F          
----------- -----------
14          15

The moral of the story is that IsNumeric() <> CanBeConvertedToNumeric().

So what is the answer?  I don’t know.  You would need to customize the solution to meet your specific situation.  Jeff Moden suggests an IsAllDigits function in this thread on SQLServerCentral for instances where you want to eliminate rows with non-numeric characters.

Do you have anything that you recommend?

Posted in Bugs, Code, Code Example, Problems, SQL Server, SqlServerCentral | Leave a Comment »

Bug in Scope_Identity() Function

Posted by sqlwiseguy on March 20, 2009

Aaron Bertrand (@AaronBetrand) tweeted this tonight.  Apparently there is a bug in SQL Server 2005/2008 with Scope_Identity() related to parallelism.  You can see the bug on Connect, here.  If a fix is important to you go and vote it up. 

This is a shock to me as I use Scope_Identity() regularly and now I have to re-evaluate it’s use.  I typically use stored procedures to do single row updates and use the Scope_Identity() function to return the id to the calling application using an output parameter.  Now it looks like I’ll have to use the Output clause which requires a table variable to hold it’s results.  Within the last 2 weeks I just told someone on SSC that is had been bullet-proof for me, it has, and was bug free.  I’ll have to go back and link to this.

Posted in Bugs, SQL Server, Technology | Leave a Comment »

Profiler Bug?

Posted by sqlwiseguy on August 11, 2008

I was working with SQL Server 2005 Profiler to prepare for a talk I will be giving at the OPASS September 9th meeting (come on out and see how I do) and I saved my definition as a template. I then re-opened the template and received and error, “Invalid Event ID”. I could not figure out what had happened as 5 minutes prior I had this same Trace running, and all I had done was stop the trace and save as a template. Being intrigued by this I tried to determine what the invalid event was, but how could I do that? I used Profiler. I started a new Trace filtering out the SPID for that trace and then removing the default filter that excludes Profiler. I then opened the custom template that was failing. In my new trace I saw all the trace procedures firing and the last sp_trace_setevent was for an event if of 64000 something (I did not write down the actual event id). I then queried the sys.trace_events table to see that the highest event_id is 202. Where do the 64 thousand-something number come from? Any ideas? Is it a bug, or some kind of weird combination of events? I wish I could re-create it, but I have not been able to, any helpers out there?

Posted in Bugs, SQL Server | Leave a Comment »

Ghost of SQL Server 2005 Database Mail Reply To – Fix

Posted by sqlwiseguy on July 22, 2008

If you have been following my posts at all, you know I have had some issues with Database Mail (1, 2, 3, 4). Well the first one has been fixed, I have not tested the fix yet, by Microsoft in Cumulative Update Package 8 for Service Pack 2. The article for that is here, http://support.microsoft.com/kb/953841/en-us. Microsoft never updated my Connect post, where they said it would not be fixed unless a QFE was requested, but I’m not complaining.

Now I need to try it out on my personal SQL Server.

Posted in Bugs, Database Mail, SQL Server | Leave a Comment »

Ghost of SQL Server 2005 Database Mail Reply To, Resolution?

Posted by sqlwiseguy on April 7, 2008

Microsoft has confirmed this as a bug which has been fixed for SQL Server 2008. If I, or you, want it fixed for SQL Server 2005 a QFE needs to be submitted.

I’m not sure I like the fact that I need to go another step to get this corrected. Fortunately I was not using this feature successfully and then had it stop after applying updates. If I had been using it I would be very upset that the fix released for 2008 was not made compatible with 2005.

What do you think?

Posted in Bugs, Database Mail, SQL Server | Leave a Comment »

64-Bit Database Mail, SQL Server Agent, and Microsoft Support

Posted by sqlwiseguy on March 31, 2008

When I was preparing to do my first install of SQL Server 2005 64-bit I came across this article in Microsoft Help and Support: http://support.microsoft.com/default.aspx/kb/908360. The article states that, “SQL Server Agent is not integrated with Database Mail or with SQL Mail in Microsoft SQL Server 2005 64-bit editions…” with a note that, “In SQL Server 2005 Service Pack 1 (SP1), you can use SQL Server Agent to interact with Database Mail as the mailing system on 64-bit operating systems.” Well, after reading the article, I was not sure if SQL Server Agent supported Database Mail without going through the steps in the article or not. Did SP1 fix an issue in the RTM edition or did SP2 cause an issue?

I installed SQL Server and added SP2. I then setup Database Mail and found the bug I note in my earlier posts about The Ghost of Database Mail (1 and 2). I also tested using Database Mail with SQL Server Agent Job Notifications and Alerts and I was happy to find that it does indeed work and Microsoft’s Help and Support article should state in it’s note that, “SP1 and later adds support for Database Mail with SQL Server Agent”. IMHO this would make it clear that Database Mail integration is now supported on the 64-bit platform.

Posted in Bugs, Microsoft Support, SQL Server | Leave a Comment »

Update on the Ghost of Database Mail

Posted by sqlwiseguy on March 28, 2008

After having posted the problem on SQL Server Central and getting feedback (forum discussion found here). It has been determined that the Reply To phantom is caused by applying .NET Framework 2.0 SP1. I have submitted the problem to Microsoft through Microsoft Connect. Go here if you have experienced it and want to add your voice as well.

As an aside, if you are an IT professional and do not participate in your fields on-line forums you should. You learn a lot and can be a help to others in your profession.

Posted in Bugs, Database Mail, SQL Server | Leave a Comment »