Viewing 13 posts - 271 through 283 (of 283 total)
This will do what you want:
Declare @Letter char; Set @Letter = 'B'; Select Description From TheTable Where Left(Description, 1) >= @Letter Order By Description;
However, it's going to be a...
June 1, 2007 at 12:46 pm
I took the table def supplied by Lynn and created a primary key on (client, typecode, grp). That at least turned a table scan into a clustered index scan. Then...
June 1, 2007 at 11:49 am
So, if I read this correctly, you are inserting all the records into the table, then going through and deleting the older duplicates. This seems straightforward but I have a...
June 1, 2007 at 10:39 am
This is bare bones but it will do what you want. I didn't write it in the form of a function, I trust you can do that. The following creates...
May 30, 2007 at 8:04 pm
The best answer was the three-stage DTS procedure. The proc would actually be simple -- an update and an insert statement.
Let's say your SQL Server table has an identity column...
May 30, 2007 at 5:12 pm
That doesn't hold water. There will be business rules concerning withdrawals and a Withdraw function/procedure will incorporate those rules. There will also be business rules concerning deposits and a Deposit...
May 29, 2007 at 2:54 pm
As has already been pointed out, your main problem is your having the IPs stored as strings, so comparison are lexical, i.e. '10' comes before '2'. However, if you really...
May 24, 2007 at 11:25 am
I generally prefer to use between to compare dates as functions on the column will prevent index usage.
This is true but I rarely see only the date field in the...
May 24, 2007 at 10:56 am
It may be frustrating and taking seemingly forever, but usually when the system balks at what you are trying to do, it is trying to tell you something important.
The first...
May 24, 2007 at 10:30 am
You're facing two problems:
May 21, 2007 at 12:09 pm
Sorry, guys. I just noticed that in the function and the select statement at the end, the table is called days_area instead of DaysArea. I had started to edit my...
May 17, 2007 at 12:42 pm
Here's a solution. It involves the use of a user function so it's not useful to the original poster. But is does illustrate how absurdly complicated a restriction on the...
May 17, 2007 at 12:22 pm
Here's a partial answer:
select ID, CurrentArea, RunDate, InvoiceID, count(*) as Days from (select ID, CurrentArea, RunDate, InvoiceID from dbo.DaysArea Today ...
May 16, 2007 at 4:14 pm
Viewing 13 posts - 271 through 283 (of 283 total)