Viewing 15 posts - 17,686 through 17,700 (of 18,926 total)
Not sure you need the not null... cause if there's no price then there's no row so the join won't update the line at all.
May 20, 2005 at 1:42 pm
Yes, you should always specify the column names for the insert before inserting the valu.
ex :
Insert into dbo.DummyTable (col1, col2, name) Select col1, col2, name from dbo.Table2.
That way sqlserver...
May 20, 2005 at 12:35 pm
My mistake.. I was referring to this script :
CREATE TABLE [dbo].[TypesCommentairesADPS] (
[PkTypeCommentaireADP] [int] IDENTITY (1, 1) NOT NULL ,
[DescTypeCommentaireADP] [varchar] (50) COLLATE French_CI_AS NOT NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[TypesCommentairesADPS]...
May 20, 2005 at 12:17 pm
I already posted something that disproves that in this very thread... I think this is a lost cause. Let him not use the order by and get bitten later...
May 20, 2005 at 12:15 pm
On a last note, and outer join (left, right or cross) with a where condition like : where SomeCol = @SomeValue basically becomes an inner join if the search criteria...
May 20, 2005 at 11:33 am
Select C.CategoryID, C.name, count(*) as Total from dbo.Category C LEFT OUTER JOIN dbo.Comments CM on C.CategoryID = CM.CategoryID and CM.UserId = @UserId
GROUP BY C.CategoryID, C.name
ORDER BY C.name
May 20, 2005 at 11:30 am
Are the columns chars() or varchars()? If you use varchar instead of char then the trailing spaces will be removed automatically (or actually not added at all).
May 20, 2005 at 11:28 am
You should always use owner.objectname. You only need to add the database name for cross database/cross server queries.
May 20, 2005 at 11:26 am
BTW this assumes that Pattern and Color cannot contain nulls
May 20, 2005 at 10:21 am
INSERT INTO tblCatalog ( Product_ID, img )
SELECT Product_Id, Pattern + '-' + Color + '.jpg' as img
FROM dbo.Product_Dimension
May 20, 2005 at 10:20 am
Do you mean something like this?
Select C.CategoryID, C.name, count(*) as Total from dbo.Category C LEFT OUTER JOIN dbo.Comments CM on C.CategoryID = CM.CategoryID
GROUP BY C.CategoryID, C.name
ORDER BY C.name
May 20, 2005 at 10:19 am
I can't help you any further than this... maybe some dts guru will be more fit to solve your problem than me.
May 20, 2005 at 9:37 am
Wow, that's a nice quote.
May 20, 2005 at 9:36 am
you don't need to specify the dbname unless you are connection do northwind and want to get data from pubs.
It's considered a best pratice to ALWAYS specify the owner of...
May 20, 2005 at 9:18 am
Viewing 15 posts - 17,686 through 17,700 (of 18,926 total)