Viewing 15 posts - 91 through 105 (of 190 total)
Greg Charles (9/11/2009)
September 11, 2009 at 11:09 am
Hmm.. let me try this out and then ill get back to you here. My column is a char... Im going to change it to varchar then insert data and...
August 31, 2009 at 10:52 am
Check the below article out. It gives a nice explanation along with SQL 2000 and 2005 syntax and query idea's.
http://code.msdn.microsoft.com/SQLExamples/Wiki/View.aspx?title=DuplicateRows
Thanks,
S
August 31, 2009 at 7:26 am
I agree with the above post. Unless you have some criteria defining with what you want back in that one row, it doesnt make sense. Or maybe we're just missing...
August 30, 2009 at 4:34 pm
can you tell us what you're expecting in a result-set form?
like:
StoreID NumberofTotalProductPerStore
1 24
2 35
3 29
Something similar would help.
Thanks,
S
August 28, 2009 at 1:18 pm
Hey Buddy,
You really need to use aliases! In your joins just assign each table a letter or point of reference that you think makes sense.
For example... Server.Database.SchemaName.TableName AS a
...and...
August 28, 2009 at 7:06 am
Check your aliases closely if you have any.
August 27, 2009 at 10:41 am
Assuming the empid is the unique key, you can use a self join from plan A table and in your where clause specify that you're looking for nulls. Where ever...
August 27, 2009 at 7:03 am
Try using this:
BEGIN TRY
BEGIN TRANSACTION
TSQL Logic here
COMMIT
END TRY
--Catch any errors above
BEGIN CATCH
IF @@TRANCOUNT > 0
ROLLBACK
DECLARE @ErrMsg nvarchar(4000), @ErrSeverity int
SELECT @ErrMsg = ERROR_MESSAGE(), @ErrSeverity = ERROR_SEVERITY()
RAISERROR(@ErrMsg, @ErrSeverity, 1)
END CATCH
August 25, 2009 at 7:31 am
colin Leversuch-Roberts (5/14/2009)
try this
--This query will list the top 50 queries which used the...
August 12, 2009 at 9:26 am
So...why exactly is this happening? I thought the whole 'This is a test string' without the quotes would show up in my result-set.
August 10, 2009 at 6:49 am
Got it. Thanks for the confirmation :w00t:
August 7, 2009 at 9:37 am
AA Hamed,
I have done multiple updates/inserts using left outer joins and they worked like a charm. I could have used EXCEPT but.. I have 9 update/inserts executing in 19 seconds....
August 7, 2009 at 6:39 am
Viewing 15 posts - 91 through 105 (of 190 total)