Pages

Monday 28 June 2010

A week-end in the South of France using the Ipad

Borrie

I enjoyed a long and sunny week-end in the south of France at a friend’s place (Gordes, Provence). I spent many hours near the swimming pool toying with the Ipad (the first Apple device I’ve ever bought).

I like the sexiness of the hardware but plenty of little things keep annoying me.

Intended home usage:

  • read my RSS feeds
  • browse Oreilly Safari
  • read kindle books

I’m still looking for:

  • A better browser, because Safari lacks some really obvious features such as tabs or page text search.
    • A1 Perfect browser: would be great if it didn’t reload the last page every time you switch back to it.
    • ICab Mobile
      • To be tried
  • a RSS Feed reader that compares to Feedly. I use Feedly on the desktop but it does not exist on the Ipad yet so I looked for alternatives:
    • Feedler:
      • the experience is similar to Google Reader, hence functional but a bit boring.
    • Reeder: could not install
    • Early Edition:
      • Visually pleasant although not as much as feedly
      • Very slow to refresh
      • imports feeds from Google Reader but does not sync automatically.
      • No mark for later function
      • Doesn’t remember what you read.
      • Displays original posts with embedded browser instead of opening Safari (which a good thing).

Some random observations:

  • You can’t see anything on the screen if you wear polarising sunglasses. :D Not a problem but it’s the first time I notice something like this on any device…. Update: (12/09/2010) When using polarised RayBan sunglasses, the IPad screen becomes invisible if you hold it in portrait mode. In landscape mode it’s fine.
  • The absence of notice means you have to play around to discover some features of the hardware/OS/virtual keyboard, that’s actually quite fun.
  • The WIFI issue
    • I observed that my Ipad loses the Wifi connection if the connection is unused for more than 5 minutes (does not occur at 4 minutes).
    • Router tweaks I tried with no success:
      • Disabled security
      • Changed the wireless channel
      • Switched down to 802.11b.
      • Used a static IP address
      • Updated the firmware of my Belkin F5D8635v1 from 1.00.17 to 1.00.23

Apps reviews:

Wired
PadGadget

Update: (07/08/2010)
Safari Books Online plans on releasing an app for the Ipad this summer.

Sunday 20 June 2010

SQL Server and Notifications

Chaps from Microsoft gave us a presentation of StreamInsight at work the other day.

Following this I started digging around the whole SQL Server notification/event thing: how can an application be notified of a data change instead of polling the database like a drowsy lobotomised lemming?

Service Broker

Messaging infrastructure for SQL Server. To enable it on a database, right-click the database in SSMS, click Properties > Options > Broker Enabled

Service Broker
Servicer Broker Programming

T-SQL has a few constructs dedicated to using the service broker.

Query Notifications

Requires Service Broker to be installed on the current SQL Server instance and enabled for the current database.

Using query notifications
Query Notifications in SQL Server (ADO.NET)

SqlDependency

This is the class you use to implement Query Notifications in a .NET app. It is supposed to be used by server apps (ASP.NET for instance). The documentation warns it is not designed for client apps. It probably doesn’t scale too well.

SqlDependency class
Detecting Changes with SqlDependency (ADO.NET)

SqlDependency wraps a lot of Service Broker-specific T-SQL code

Notification Services

SQL Server 2005 only, not 2008. This is a publish/subscribe messaging service.
Notification Services Tutorial
What does Notification Services do?

StreamInsight

Big Diagram
StreamInsight Installation
Download
Deployment model
Concepts

Other Stuff…

  • Change Data Capture / Change Tracking

This is more for auditing purposes: allows you to easily query historical changes made to the data without having to write tons of error-prone code in triggers (as I saw being done on an Oracle database by a client I used to work for…)

Data Capture and Change Tracking compared

  • WAITFOR

Can be used to delay a statement: block for 2 minutes before running a statement for instance or can be used to schedule a statement to run at a specified time.

Using WAITFOR
WAITFOR (Transact-SQL)