Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Site Related Forums
 The Yak Corral
 What is your DBA Espresso Rating?

Author  Topic 

Wanderer
Master Smack Fu Yak Hacker

1168 Posts

Posted - 2006-07-31 : 11:47:23
[code]select count(*) as [Number of Espresso's the DBA Requires]
from sys.sysusers NormalUsers
left join
(select UID from sys.sysusers where status = OBJECT_ID('UserHasAClue')) UsersWithAClue
on NormalUsers.UID = UsersWithAClue.UID
WHERE UsersWithAClue.UID IS NULL
[/code]
*##* *##* *##* *##*

Chaos, Disorder and Panic ... my work is done here!

Wanderer
Master Smack Fu Yak Hacker

1168 Posts

Posted - 2006-07-31 : 11:48:15
Yay for me as a DEV DBA:


Number of Espresso's the DBA Requires
-------------------------------------
16


*##* *##* *##* *##*

Chaos, Disorder and Panic ... my work is done here!
Go to Top of Page

spirit1
Cybernetic Yak Master

11752 Posts

Posted - 2006-07-31 : 12:06:22
i don't drink any kind of coffee...



Go with the flow & have fun! Else fight the flow
blog thingie: http://weblogs.sqlteam.com/mladenp
Go to Top of Page

Wanderer
Master Smack Fu Yak Hacker

1168 Posts

Posted - 2006-07-31 : 12:15:05
Picky-Picky.....
This is SQL2000 and SQL2005 compliant - anyone check if it works on SQL 7.0 ?

SET NOCOUNT ON
DECLARE @SQLCmd varchar(500)
DECLARE @PreferredCopingDrink varchar(50)

SET @PreferredCopingDrink = 'Espresso' --or Beer, etc.
SET @SQLCmd = 'select count(*) as [Number of '+@PreferredCopingDrink+'''s the DBA Requires]
from sysusers NormalUsers
left join
(select UID from sysusers where status = OBJECT_ID(''UserHasAClue'')) UsersWithAClue
on NormalUsers.UID = UsersWithAClue.UID
WHERE UsersWithAClue.UID IS NULL'
EXEC (@SQLCmd)


*##* *##* *##* *##*

Chaos, Disorder and Panic ... my work is done here!
Go to Top of Page

spirit1
Cybernetic Yak Master

11752 Posts

Posted - 2006-07-31 : 12:27:47
beer... mmmmmmm



Go with the flow & have fun! Else fight the flow
blog thingie: http://weblogs.sqlteam.com/mladenp
Go to Top of Page

Wanderer
Master Smack Fu Yak Hacker

1168 Posts

Posted - 2006-07-31 : 12:46:35
so ... what's your number then?

*##* *##* *##* *##*

Chaos, Disorder and Panic ... my work is done here!
Go to Top of Page

spirit1
Cybernetic Yak Master

11752 Posts

Posted - 2006-07-31 : 13:06:13
of beers?
at work = 0
in a bar... well depends on a night...
we usually go out at 10 pm and come home at 5 am so in that time... about 7 or 8... half liters of course
anything less is for wussies



Go with the flow & have fun! Else fight the flow
blog thingie: http://weblogs.sqlteam.com/mladenp
Go to Top of Page

Stoad
Freaky Yak Linguist

1983 Posts

Posted - 2006-07-31 : 14:43:16
Mladen!

The meaning of life is that it stops! (c)


======================
Let me hug & kiss you...

Go to Top of Page

spirit1
Cybernetic Yak Master

11752 Posts

Posted - 2006-07-31 : 16:48:39
excellent



Go with the flow & have fun! Else fight the flow
blog thingie: http://weblogs.sqlteam.com/mladenp
Go to Top of Page

Stoad
Freaky Yak Linguist

1983 Posts

Posted - 2006-08-01 : 02:08:04
Not mine! It's Franz Kafka!


======================
Let me hug & kiss you...

Go to Top of Page

elwoos
Master Smack Fu Yak Hacker

2052 Posts

Posted - 2006-08-01 : 03:16:23
quote:
anyone check if it works on SQL 7.0 ?


Yes it does

-----------

Don't worry head. The computer will do all the thinking from now on.
Go to Top of Page

Wanderer
Master Smack Fu Yak Hacker

1168 Posts

Posted - 2006-08-01 : 05:01:33
quote:
Originally posted by elwoos

quote:
anyone check if it works on SQL 7.0 ?


Yes it does

-----------

Don't worry head. The computer will do all the thinking from now on.



:-).... I think I would consider change my sig to that, but I don't like SIG's that are too long, so I guess I'll skip it...

*##* *##* *##* *##*

Chaos, Disorder and Panic ... my work is done here!
Go to Top of Page
   

- Advertisement -