Author |
Topic |
russell
Pyro-ma-ni-yak
5072 Posts |
Posted - 2012-02-17 : 15:29:03
|
An email I received:
What I'm hoping for is enough permissions in database "xyz" to create and modify stored procs, and of course, execute any proc that I create. It is odd to me that I can create them now, but not run them. I have been a DBA in the past, and I do know my way around SQL Server. I don't want any permissions on anything even close to production, but I would like more power in the dev environment.
And the proc in question
CREATE PROCEDURE [dbo].[TRIM_TABLE] (@tablename varchar(100)) AS BEGIN
SET NOCOUNT ON;
declare @sqlstring varchar(1000) create table #tempSQL (sql varchar(1000))
declare sqlCursor CURSOR FAST_FORWARD FOR select sql from #tempSQL
INSERT INTO #tempSQL select ('UPDATE '+@tablename+' '+ 'set ['+cols.name+'] = ltrim(rtrim(['+cols.name+']));') as sql from sys.columns cols, sys.tables tabs, sys.types where 1=1 and tabs.name = @tablename and tabs.object_id = cols.object_id and cols.system_type_id = sys.types.system_type_id and sys.types.collation_name like 'SQL_%' OPEN sqlCursor FETCH NEXT FROM sqlCursor INTO @sqlString WHILE @@FETCH_STATUS = 0 BEGIN exec (@sqlstring) FETCH NEXT FROM sqlCursor INTO @sqlString END
CLOSE sqlCursor DEALLOCATE sqlCursor END
GO
|
|
webfred
Master Smack Fu Yak Hacker
8781 Posts |
Posted - 2012-02-17 : 15:42:23
|
What would you say?
What is the meaning of DBA in your linguistic usage?
No, you're never too old to Yak'n'Roll if you're too young to die. |
 |
|
robvolk
Most Valuable Yak
15732 Posts |
Posted - 2012-02-17 : 17:16:21
|
My answer would include combinations of "fuck", "no", "are", "you", "crazy", "no" and "way". I'm not sure I could assemble them into a coherent sentence either, but I have that trouble constantly, especially on SQLTeam posts.
I would gladly have a quiet, instructive intervention on what is wrong with that stored procedure, but couldn't guarantee I wouldn't pull their arms out and beat them with it before I finished. |
 |
|
webfred
Master Smack Fu Yak Hacker
8781 Posts |
Posted - 2012-02-17 : 17:58:20
|
LIKE
No, you're never too old to Yak'n'Roll if you're too young to die. |
 |
|
jezemine
Master Smack Fu Yak Hacker
2886 Posts |
Posted - 2012-02-17 : 19:46:41
|
rob, you forgot "you're" and "fired"
elsasoft.org |
 |
|
russell
Pyro-ma-ni-yak
5072 Posts |
Posted - 2012-02-20 : 10:17:58
|
I was too flabbergasted to reply for most of the day. |
 |
|
JimL
SQL Slinging Yak Ranger
1537 Posts |
Posted - 2012-02-20 : 16:03:44
|
Did you report him for smoking crack on the job.
D umb B onehead A sshole
Jim Users <> Logic |
 |
|
Michael Valentine Jones
Yak DBA Kernel (pronounced Colonel)
7020 Posts |
Posted - 2012-02-20 : 16:53:24
|
I would really like to know why they want to do this.
CODO ERGO SUM |
 |
|
russell
Pyro-ma-ni-yak
5072 Posts |
Posted - 2012-02-20 : 17:31:09
|
Because their ETLs are no good I suspect |
 |
|
DonAtWork
Master Smack Fu Yak Hacker
2167 Posts |
Posted - 2012-02-21 : 11:07:37
|
an old Cajun expression would suffice:
Oh HELL fuck ass no.
http://weblogs.sqlteam.com/jeffs/archive/2008/05/13/question-needed-not-answer.aspx How to ask: http://weblogs.sqlteam.com/brettk/archive/2005/05/25/5276.aspx For ultra basic questions, follow these links. http://www.sql-tutorial.net/ http://www.firstsql.com/tutor.htm http://www.w3schools.com/sql/default.asp |
 |
|
elwoos
Master Smack Fu Yak Hacker
2052 Posts |
Posted - 2012-02-22 : 04:50:49
|
I think I would say (excuse any dodgy spelling) "twll dyn i chi".
I knew welsh would come in useful one day :)
For those who know even less welsh that me here is my effort at how to pronounce it
twll - too with a throaty ck (as in yuck) sound at the end dyn - dean i - eee (rhymes with tea) chi - short throaty sound like when your clearing your throat, ending with an ee sound
Google doesn't translate it very well but you will get the idea
steve
-----------
What color do you want that database? |
 |
|
elwoos
Master Smack Fu Yak Hacker
2052 Posts |
Posted - 2012-02-22 : 04:54:06
|
You could also say "Which company were you a DBA for?" then ring them up and offer to fix their database for a nice consultancy fee 
steve
-----------
What color do you want that database? |
 |
|
RickD
Slow But Sure Yak Herding Master
3608 Posts |
Posted - 2012-02-22 : 07:24:20
|
We don't always get what we like and this is one of those.
Or
How long was it before the company you were a DBA for went bust? |
 |
|
RickD
Slow But Sure Yak Herding Master
3608 Posts |
Posted - 2012-02-22 : 07:26:01
|
We don't always get what we like and this is one of those.
Or
How long was it before the company you were a DBA for went bust? |
 |
|
|