Hi AA
Unfortunately the counter is not always sequentially ordered and may contain gaps so it can't be used in that way :(
Hi Vongrunt,
In my sample data I need the three rows returned seperately.
1 2005-01-01 01:00:00 2005-01-01 01:01:00
2 2005-01-01 01:05:00 2005-01-01 01:10:00...
I am working on the assumption that if a fault ends at a particular time and another starts at that exact same time, both records would be valid.
I will ultimately be calculating fault durations. I already have this query but because I have all the symptomatic faults in the results it is...
Hello
I have a table that stores start and end times for machine faults. The times often overlap because when one fault occurs it can cause a knock on effect and trigger several other fault conditions.
I need to query this table and only bring back the rows showing the first fault in the...
Hi James
Thanks for the quick response. What you say makes perfect sense to me and is how I originally perceived it ... it's just that I've had conflicting answers from different parties!
guess it's one of those grey areas MS love so much
thanks
Salma
Hi
I feel that I understand MS CAL licencing whereby any client accessing the server either directly or indirectly requires a CAL (either Device or User CAL or a Processor licence).
However if you export data from SQLServer into a CSV file, is a CAL required for anyone who views that CSV file...
you can query the two tables seperately and then use a UNION command to merge the results
eg.
SELECT c1 FROM Table1
UNION
SELECT c1 FROM Table2
there are several options for the UNION command which can be found in the SQLServer Books Online
not too sure this is what you want but ...
you can run VBScript code using the Windows Scripting Host (WSH) engine (CSRIPT.EXE). This is available as a free download from Microsoft's website and once installed and registered, allows you to run any VBScript from a file. All you need to do is...
The stored procedure is easy enough to create using the getdate() function to find data older than two months
You can then create a job in SQLExecutive (accessed from Enterprise Manager) to run your sp and create a schedule to run it daily.
The HOW TO section of SQL Server Books Online details...
You need to use the stored procedure sp_execute_sql instead of the execute command
This stored procedure will simply run any SQL statement that is passed to it. The only thing to bear in mind is that if you pass a variable, it has to be of type unicode
Modified Script
declare @tablename...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.