Viewing 15 posts - 181 through 195 (of 211 total)
Yep, you're right Jack. For some reason I went off under the assumption that one or the other would be populated but not both. Plus my query would've need to...
_____________________________________________________________________
- Nate
September 24, 2008 at 8:59 am
I generally like to avoid using ORs in my WHERE clause so I modified your statement to use an AND. Check out the query plans for these two and see...
_____________________________________________________________________
- Nate
September 24, 2008 at 6:25 am
I run the following script when I need to close out connections.
alter database [db_name] set SINGLE_USER with rollback immediate
go
alter database [db_name] set MULTI_USER with rollback immediate
go
_____________________________________________________________________
- Nate
September 24, 2008 at 6:05 am
Steve Jones - Editor (9/18/2008)
Which event is this?
SP: StmtCompleted
Issue comes up from time to time because of legacy code that uses @Password as an input parameter.
_____________________________________________________________________
- Nate
September 18, 2008 at 2:37 pm
Don't think there is a job option to do this. You could try managing it through a process table that each step would update and validate against.
Ex.
Job Step 1
- does...
_____________________________________________________________________
- Nate
September 18, 2008 at 7:27 am
Multiply the column by .01
select [col_name] * .01 from [tbl_name]
_____________________________________________________________________
- Nate
September 18, 2008 at 7:19 am
Your update statement is referencing a table in the WHERE clause. You need to reference ComputerOperationsServerInformation in your FROM clause to get this to work.
Try this instead:
updateb
setb.SupportedByText = c.[Support Team]
fromBuilds...
_____________________________________________________________________
- Nate
September 18, 2008 at 7:15 am
Try this:
selectso.[name] as tbl_name
, si.[name] as indx_name
, STATS_DATE(si.[id], si.indid) as StatisticsDate
fromdbo.sysobjects so
inner join dbo.sysindexes si on so.[id] = si.[id]
whereINDEXPROPERTY(si.[id], si.[name], 'IsStatistics') = 0 -- remove statistics
_____________________________________________________________________
- Nate
September 18, 2008 at 7:03 am
Have you tried running CHECKPOINT against the db before DBCC SHRINKFILE?
_____________________________________________________________________
- Nate
September 15, 2008 at 10:54 am
Ok, found the answer to my question...stumbled across this link (below) in another discussion. Gives background of sysprocesses columns added through SQL Server 2000 SP3 and stored proc example to...
_____________________________________________________________________
- Nate
September 12, 2008 at 1:14 pm
This will also work for the example given, however, the number of characters returned is directly dependent on the precision and scale you specify.
declare @num float
set @num = -888.99
select len(convert(decimal(10,2),@num))
Converting...
_____________________________________________________________________
- Nate
September 12, 2008 at 10:23 am
Don't call the parameter when you exec the SP
exec my_sp
@p2 = [some value]
, @p3 = [some value]
go
_____________________________________________________________________
- Nate
September 12, 2008 at 9:41 am
Do you have an example of what you're trying to achieve?
_____________________________________________________________________
- Nate
September 12, 2008 at 9:33 am
I agree with Jack that best practices are relative to what you're trying to achieve but here are a couple things I constantly ding our developers on.
- Use of SELECT...
_____________________________________________________________________
- Nate
September 12, 2008 at 9:28 am
What is the job doing to process the AS400 data? If its calling a DTS package, BCP or using SQL statement(s) you might be able to extract out the job...
_____________________________________________________________________
- Nate
September 11, 2008 at 11:05 am
Viewing 15 posts - 181 through 195 (of 211 total)