Viewing 15 posts - 14,716 through 14,730 (of 15,381 total)
LOL. Yeah if this is something you are going to have to do over and over then maybe you need to look at the process that is creating your new...
May 10, 2011 at 7:39 am
Given the challenge of needing to keep the existing values it may actually be easier and quicker to just edit the tables in SSMS over writing a script.
May 10, 2011 at 7:33 am
something like this may get you started in the direction you are heading.
select 'alter table ' + name + ' add ' + name + 'ID int identity not null;'
from...
May 10, 2011 at 7:17 am
That one "depends". For example, I had somebody last week ask me the syntax for an xml comment via instant message. I agree that there are plenty of bad answers...
May 10, 2011 at 7:00 am
Me too. Makes me nearly pee myself every time I send somebody a link there. Even better is the response I get from people around the office when the ask...
May 9, 2011 at 3:14 pm
BitBucket - You need to know about this site.
This is the perfect link for a response to this thread.
😀
May 9, 2011 at 2:55 pm
Not sure what information you are looking for or how you are wanting to get this information. With some more details your chances of an answer will increase greatly.
May 9, 2011 at 2:50 pm
Please don't continue to post the same question repeatedly. The reason nobody responded to your first post is because you didn't provide any detailed information about your problem.
Please direct all...
May 9, 2011 at 2:48 pm
You need to post some ddl and sample data so that we can help you. Take a look at the link in my signature for answers on how to get...
May 9, 2011 at 2:44 pm
Lowell (5/5/2011)
Sean Lange (5/5/2011)
Lowell you beat me to the punch again. 😛I'm hitting a lot of low hanging fruit today! I'll leave complicated PIVOTS and recursive CTE's to you, ok?
Sweet...
May 5, 2011 at 1:10 pm
Lowell you beat me to the punch again. 😛
May 5, 2011 at 12:51 pm
Your update is using a subselect. My guess is the error is that a subquery can't return more than 1 value??
Try this:
UPDATE ADDRESS
SET ADDRESS_STATE_ID = s.STATE_ID
FROM ADDRESS a
INNER JOIN...
May 5, 2011 at 12:51 pm
something like
select AVG(datediff(d, DINVPDOF, DOCDATE)) from table
May 5, 2011 at 7:59 am
LutzM (5/4/2011)
It might be a better way to use ROW_NUMBER() instead of the COUNT(*) in a subquery approach.
Would it be possible to post...
May 4, 2011 at 3:37 pm
Since you are updating all the records where field1 = 0 to the same static value can you just calculate that value and put in a variable?
declare @newVal char(8)
select @newVal...
May 4, 2011 at 3:15 pm
Viewing 15 posts - 14,716 through 14,730 (of 15,381 total)