Robert,
This is what was in the event viewer:
Log Name: Application
Source: Application Error
Date: 11/16/2008 7:22:57 AM
Event ID: 1000
Task Category: (100)
Level: Error
Keywords: Classic
User: N/A
Computer: ***-PC
Description:
Faulting application devenv.exe, version 8.0.50727.867, time stamp 0x45d2c842, faulting module vdt80.dll, version 8.0.50727.762, time stamp 0x45716c58, exception code 0xc0000005, fault offset 0x0004f839, process id 0x1a64, application start time 0x01c947ee2fd2c320.
Event Xml:
<Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
<System>
<Provider Name="Application Error" />
<EventID Qualifiers="0">1000</EventID>
<Level>2</Level>
<Task>100</Task>
<Keywords>0x80000000000000</Keywords>
<TimeCreated SystemTime="2008-11-16T13:22:57.000Z" />
<EventRecordID>9245</EventRecordID>
<Channel>Application</Channel>
<Computer>***-PC</Computer>
<Security />
</System>
<EventData>
<Data>devenv.exe</Data>
<Data>8.0.50727.867</Data>
<Data>45d2c842</Data>
<Data>vdt80.dll</Data>
<Data>8.0.50727.762</Data>
<Data>45716c58</Data>
<Data>c0000005</Data>
<Data>0004f839</Data>
<Data>1a64</Data>
<Data>01c947ee2fd2c320</Data>
</EventData>
</Event>
It is clearly the date function. I ran
SELECT * FROM Attendance WHERE DateOfService BETWEEN @Date1 AND @Date2
and it worked perfectly. However
SELECT * FROM Attendance WHERE date(DateOfService) BETWEEN @Date1 AND @Date2
caused a crash without error message.