Viewing 15 posts - 1,696 through 1,710 (of 1,923 total)
I would use Dynamic Update query in this context... But we must also write that dynamic query to neglect SQL-Injections... But when the number of columns to be updated is...
April 25, 2010 at 10:24 pm
This would work for u!
;WITH CTE (Key1,MAX1,SUM2)
AS
( SELECT Key1, MAX(VAL1) as MAX1, SUM(VAL2) as SUM2 FROM @TableVar
GROUP BY KEY1
)
SELECT TAB.Key1 , TAB.VAL1 MAX1 , CTE.SUM2, TAB.SOMEVALUE
FROM CTE CTE
JOIN @TableVar...
April 25, 2010 at 10:16 pm
john barnett (4/25/2010)
ColdCoffee's code runs your stored procedure from your posting. It assumes it is in the same database as your code and has the same owner.
Spot On, John..
And Nabha's...
April 25, 2010 at 7:37 am
Thanks, Jeff, for posting your approach.. As i dont have SSMS at home, i will check out your code tomorrow and let you know..
But i got a doubt here.....
April 24, 2010 at 8:45 pm
Use the statement like this
DECLARE @OUTPUT_COUNT INT
EXEC @OUTPUT_COUNT = sp_GetMessageCount '<Your Table Name>'
SELECT @OUTPUT_COUNT
April 24, 2010 at 8:40 pm
SSMS = Sql Server Management Studio.. Invoke it, Open the Database Node and follow what Mr.Lowell had put in his post...Hope this helps you..
April 24, 2010 at 12:56 pm
Tom.Thomson (4/24/2010)
ColdCoffee (4/24/2010)
Me born in , une fois par le territoire français (once a french territory) PONDICHERRY, in INDIA! 😉
And now working in chennai (again in INDIA) for...
April 24, 2010 at 12:47 pm
Tom.Thomson (4/24/2010)
ColdCoffee (4/24/2010)
Me born in , une fois par le territoire français (once a french territory) PONDICHERRY, in INDIA! 😉
And now working in chennai (again in INDIA) for...
April 24, 2010 at 12:46 pm
Nice thread, imho!!
Me born in , une fois par le territoire français (once a french territory) PONDICHERRY, in INDIA! 😉
And now working in chennai (again in INDIA) for one among...
April 24, 2010 at 10:22 am
Bhuvnesh (4/24/2010)
Jeff Moden (4/23/2010)
Bhuvnesh (4/23/2010)
Also check ANSI_NULL and ANSI_PADDING settings on both databases ?Spot on.
Jeff , i didnt get you here ? did i suggest wrong workaround ?
I guess...
April 24, 2010 at 10:10 am
I have 2 solutions in mind.
Solution 1:
1. Ask the csv team to tel give us if the extra columns will be added in today's file.
2. Create many format (*.fmt) files...
April 24, 2010 at 12:35 am
Jeff Moden (4/23/2010)
Wow... sorry about that, folks. I really lost track of this post.Simon, after only 5 months of delay :blush:, do you still need any help on this?
Jeff,...
April 24, 2010 at 12:25 am
Harsha, there are lot of ways (fast ways included) for performing group concatenation in MS SQL... if u could please post us DDLs for table structures (CREATE TABLE scripts), sample...
April 23, 2010 at 11:46 pm
AndrewSQLDBA (4/22/2010)
Hope that you don't mind if I take the code apart and figure out how it works, and what it does
At your will, brother!
1. The CTE will collect...
April 22, 2010 at 7:10 am
AndrewSQLDBA (4/22/2010)
I want only the name associated with the Max(ROWID)
Check out the last post of mine, you will get only the last inserted row for a date, the date,...
April 22, 2010 at 7:05 am
Viewing 15 posts - 1,696 through 1,710 (of 1,923 total)