Viewing 15 posts - 466 through 480 (of 684 total)
Hi Rama,
You can use the procedure, sp_msforeachtable. In fact, you can probably use it in place of your cursor.
declare @cmd nvarchar(4000)
--disable all table constraints
exec sp_msforeachtable 'alter table ? nocheck...
July 20, 2006 at 2:02 am
You'll have to restore the backup from a week ago to another database. Find the records that were deleted and insert them into the table in the original database.
Hope...
July 19, 2006 at 6:57 am
If what you want to do is insert the resultset of stored procedure into a table you could do:
insert into #mytable
exec server.database.dbo.sp_call
What you cannot do is treat it as...
July 18, 2006 at 9:33 am
Ah, I see.
Do you have to use OPENQUERY? I'm assuming you've got a linked server set up, in which case can't you execute the stored procedure with four-part naming?
exec...
July 18, 2006 at 9:03 am
I've tried to use a temp table with openquery and it works fine for me.
I just did:
insert into #mytemp
select * from openquery (server, 'exec sp_help')
And that worked fine. I'm...
July 18, 2006 at 8:37 am
You'd need to use a temp table or table variable. Is there any reason why you don't want to use one?
I must admit that the use of a While...
July 18, 2006 at 7:59 am
Yes,
Both instances can be running at the same time.
July 18, 2006 at 7:51 am
Hi,
this is possible. You just install SQL 2005 and set it up as a seperate instance. That's all there is to it.
July 17, 2006 at 4:39 am
Hi Carl,
When you create the tables you can create them by explicitly stating that you want the dbo user to be its owner. So, if you want to create...
July 17, 2006 at 4:37 am
Hi,
I'd advise that you use stored procedures - for a variety of reasons.
Essentially, by using stored procedures you can more effectively handle security, network traffic is reduced, execution plan is...
July 17, 2006 at 1:23 am
Hi Randy,
How big are the tables? If there are few rows in the table then the fragmentation level can appear to be high. With small tables though the...
July 17, 2006 at 1:04 am
Hi Nick,
I'm not sure I understand your question. If you're going to use an identity column then you don't need to worry about selecting the MAX(OrderLineId) - it's done...
July 17, 2006 at 1:00 am
Mahesh, try this:
declare @proc_name sysname
set @proc_name = 'enter proc name in here'
select j.name as job_name
from msdb..sysjobs j
join msdb..sysjobsteps s on s.job_id = j.job_id
where command like '%' + @proc_name + '%'
hope...
July 14, 2006 at 4:44 am
Mahesh,
Use the system proc, sp_helprotect:
exec sp_helprotect 'dbo.MyProc'
July 14, 2006 at 4:40 am
Hi,
Unfortunately, this is the case with all source control - even with source control for regular files. There is nothing to stop a developer updating the file outside of...
July 14, 2006 at 3:22 am
Viewing 15 posts - 466 through 480 (of 684 total)