Viewing 15 posts - 8,806 through 8,820 (of 13,469 total)
the example i gave you will work with absolutely any SQL command; try it before you dismiss it.
Declare @cmds Nvarchar(MAX)
Declare @obfoo varbinary(MAX)
Set @cmds = '
ALTER procedure [dbo].[sp_find]
@findcolumn varchar(50)
AS
BEGIN
...
September 8, 2010 at 10:30 am
are you sending the actual scripts fo rhte client to run, or an executable which will then execute the script after the client provides connection information to the server?
you could...
September 8, 2010 at 6:49 am
yep, so your WHERE statement would reference the THREE columns that make up your primary key:
...WHERE TableName.IdContrato = INSERTED.IdContrato
AND TableName.EiCanalId = INSERTED.EiCanalId
...
September 7, 2010 at 4:41 pm
igngua (9/7/2010)
thanks!!
im using this one because the other one cant get updated.
Ive a question if you excuse my 'newbieness', what does 'id' means.
i had to infer a lot of...
September 7, 2010 at 4:23 pm
if the query has a WHERE statement, you could make the arguments non-SARG-able, and force it to use a table scan, but it would still use an index(probably the clustered...
September 7, 2010 at 4:18 pm
I always felt those two functions should be renamed, as they are really misleading; something like ISREFERENCED would be a much better name
September 7, 2010 at 4:15 pm
I always felt those two functions should be renamed, as they are really misleading; something like ISREFERENCED would be a much better name .
September 7, 2010 at 4:14 pm
At the moment we're using an equality where clause check to determine changes between inserted and deleted which, while functional, is slower.
i think that's the only way to do...
September 7, 2010 at 3:57 pm
Craig Farrell (9/7/2010)
I think you're looking for something like:CREATE TRIGGER tr_test ON dbo.A FOR INSERT AS
UPDATE inserted
SET col1 = <value>
where col1 = 'm'
UPDATE inserted
SET col2 = <value2>
where col2 = 'n'
END
can...
September 7, 2010 at 3:43 pm
the core of the trigger is going to be something like this, but you didn't provide all the info needed. what values would col1 and col2 actually be assigned?
UPDATE...
September 7, 2010 at 3:01 pm
there's an article on something similar labeled "exotic joins" i think; if you search and read that, it can help you understand some of the less logical reasons to join...
September 7, 2010 at 1:49 pm
looked like the "enhanced" version has an error in it;
this is my slightly edited version of the same script; it runs without errors on both a 2005 and 2008 database:
September 7, 2010 at 1:00 pm
take a look at this wonderful script contribution:
Comprehensive HTML Database Documentation(Revised)[/url]
it produces well formatted, informative html document, which you could then copy and paste into excel, or open with excel.
I've...
September 7, 2010 at 11:38 am
i went to the trouble of creating a stored proc that does this;
as previous posters already identified, the actual statement is never saved...all you can do is script out the...
September 7, 2010 at 7:56 am
Viewing 15 posts - 8,806 through 8,820 (of 13,469 total)