pk software dev blog

custom microsoft .net application development

2. July 2012 22:43
by Paul

Bug Fix release for Mini SQL Query

2. July 2012 22:43 by Paul

I had an email the other day from someone having trouble with the connection editor in Mini SQL Query. It turns out that the way I had the refresh of the connection list setup, whatever the currently selected connection was before choosing a new one caused a bit of a loop if that connection failed. You can get around it by closing the editor and re-opening it etc but that is not real user friendly (hot tip!)

That bug has been there for years and I am pretty sure he was not the only one who experienced it! Thing is with software, if you have an issue you can be sure that it's happening for many more than just that one person.

If you are an open source software consumer, make sure you notify the authors of issues as their development environment may not reflect what you see. Don't expect every comment to get fixed, in fact I never even expect a reply simply because I know how busy things can get.

Anyway, there is a new release up on CodePlex: http://minisqlquery.codeplex.com/releases/view/90478

PK :-)

6. September 2010 06:04
by Paul

Mini SQL Query Quick Start

6. September 2010 06:04 by Paul

I have finally had a chance to put together a simple "Quick Start" document for Mini SQL Query. It's the main reason I have never made a formal "version 1" release!

Here is a link to the document: Mini SQL Query Quick Start [http://pksoftware.net/Content/MiniSqlQuery/Help/MiniSqlQueryQuickStart.docx]

I also "upgraded" the projects to version 3.5 of the framework as the version 2 requirement is all but gone. That was more around my usage on Windows Server 2003 etc.

 

PK :-D

20. January 2010 18:55
by Paul

Was getting 30 December 1899 on a SSIS flat file import

20. January 2010 18:55 by Paul

I had a simple SSIS flat file import going but the empty date fields were not showing up as null but "1899-12-30 00:00:00.000".

Short answer:
  • Right click "flat file source" component
  • Select "Show Advanced Editor" from the context menu
  • On the "Component Properties" tab set "RetainNulls" to true

I knew it was hidden somewhere! This post helped - http://phil-austin.blogspot.com/2007/12/retain-nulls.html - my issue was all the same except for the date value.

5. January 2010 19:47
by Paul

Was getting NULL values from Excel Worksheets during an Import

5. January 2010 19:47 by Paul

We are managing lots of "lookup data" through a big fat Excel spreadsheet. We have a simple tool that reads the sheets and produces insert statements (using ADO.NET).

The problem was that some fields were coming through NULL when I knew they were not.The short answer is "IMEX=1"

Basically the provider looks at the first few rows and guesses the type from the cell values, in my case the first few were numbers followed by text codes. When the provider gets to the text values its in “number” mode so defaults to a NULL value.

You can use the "IMEX" property to make the provider look further and go into an import mode. See the KB article for more info.

http://support.microsoft.com/kb/194124

PK  :-)

 

PS: To connect to an excel file within ADO.NET use the "System.Data.OleDb" provideran a connection string similar to:

Provider=Microsoft.Jet.OLEDB.4.0;Data Source="foo.xls";Persist Security Info=False;Extended Properties="Excel 8.0;HDR=Yes;IMEX=1"