Viewing 15 posts - 47,431 through 47,445 (of 49,571 total)
Federico Zajur (2/8/2008)
February 8, 2008 at 6:15 am
Not directly, though you could convert the month number inot a date.
SELECT DATENAME(month,'1900/' + CAST(monthNumber AS VARCHAR(2)) + '/01')
February 8, 2008 at 1:52 am
SQL has a DateName function, however it takes a datetime as a parameter, not a number
SELECT DATENAME(month, GETDATE()) AS 'Month Name'
returns
Month Name ...
February 8, 2008 at 1:30 am
in SQL 2000, I believe that rebuilding the clustred index rebuilds the nonclustered indxes. In SQL 2005, that's no longer the case.
You can just use DBCC DBReindex to rebuild all...
February 8, 2008 at 12:04 am
I'll second Loner.
Clustered PK on the identity (Custered indexes should be narrow and unique)
Add a unique nonclustered index on app_idz, msn, dash_id, received_from_dashboard
February 7, 2008 at 11:47 pm
1) No, however if you're concatenating pieces of string together, you'll need a space somewhere.
2) No. SQL doesn't care about whitespace. Lay things out that they are readable by you...
February 7, 2008 at 11:31 pm
It's declared outside of the dynamic SQL string. If you want the variable accessible inside the dynamic SQL, you either have to declare it within the dynamic SQL string, or...
February 7, 2008 at 5:49 am
Variable declared outside dynamic SQL aren't accessible within it, and vis versa
Your first line of dynamic SQL reads 'SELECT top 1 @Rank = K.RANK...'
Within the dynamic SQL, the variable @Rank...
February 7, 2008 at 5:24 am
No there aren't. You will have to disable the foreign and primary key constraints to modify the column.
February 7, 2008 at 12:31 am
If the column you're altering is the one that the constraints are on, then you'll have to drop the constraints, make the changes, then recreate the constraints.
February 7, 2008 at 12:22 am
Thanks for the info. I forgot all about the meeting.
Does anyone know how to get in on the beta exams?
February 6, 2008 at 11:04 pm
SELECT Permission_name, class_desc, OBJECT_NAME(major_id), grantee.name AS 'Permission granted to', grantor.name AS 'Permission granted by'
FROM sys.database_permissions dp
INNER JOIN sys.database_principals grantee ON dp.grantee_principal_id = grantee.principal_id
INNER JOIN sys.database_principals grantor ON dp.grantor_principal_id...
February 6, 2008 at 10:39 pm
I'd love to try it, but the cost is prohibitive, and the travel and hotels, aong with the required 4 weeks off work make it just about impossible.
Exchange rates don't...
February 6, 2008 at 10:29 pm
Viewing 15 posts - 47,431 through 47,445 (of 49,571 total)