Viewing 15 posts - 10,006 through 10,020 (of 14,953 total)
Tara (4/9/2009)
Your proc looks good but i get some errors as
Not all users can use select from sys.databases and so i want to exec proc as an id...
April 9, 2009 at 1:32 pm
";WITH" sets up a "CTE" (Common Table Expression). I used that to put a Row value into the data, so I could query that in my Where and Join...
April 9, 2009 at 1:18 pm
Did you forget the "escape" part in the actual query, or just in the forum?
April 9, 2009 at 1:05 pm
Couple ways to do it. First, you could just add an "alias" to the query you already have. Do that by typing a name for it after the...
April 9, 2009 at 1:03 pm
Put square-brackets around the underscore in the Like statement.
April 9, 2009 at 12:54 pm
There is a MUCH easier way to calculate business days between two dates. Create a calendar table, and pre-populate the data into it, then just select the rowcount between...
April 9, 2009 at 12:53 pm
Something that might make all of this a little simpler to manage would be to modify the model database so that it has the necessary roles already created in it,...
April 9, 2009 at 12:38 pm
Here's my take on it. Has some injection-proofing (might not be enough).
CREATE DATABASE DBA ;
go
USE DBA ;
go
CREATE PROC DBCreate (@DBName_in SYSNAME)
AS
SET nocount ON ;
...
April 9, 2009 at 12:36 pm
You can't do precisely that, but you can have a join with conditional logic, or you could have an inline sub-query in a case statement if you just want one...
April 9, 2009 at 11:44 am
UB (4/9/2009)
Okay may be the code gives an incorrect view of the problem I am trying to convey. I want the INSERT transactions to be audited from any user.
My...
April 9, 2009 at 11:34 am
UB (4/9/2009)
Gail,But the problem is .... the record gets inserted into Patient table and z_audit_Patient table.
thats the puzzling point for me?
As mentioned in my first post on this thread,...
April 9, 2009 at 11:32 am
Whatever user name you have it running under isn't mapped to a security account in SQL. You need to do that. Go to the properties of the user...
April 9, 2009 at 11:04 am
Judging by what you set up and what you expected to happen, it looks like what you want to do is NOT audit when certain users add data to the...
April 9, 2009 at 11:02 am
Bob Hovious (4/9/2009)
G: Do you prioritize what needs to be done first, or just take things on a FIFO basis?
Prioritize where that's clear, FIFO if priority isn't clear.
For...
April 9, 2009 at 9:55 am
Viewing 15 posts - 10,006 through 10,020 (of 14,953 total)