Viewing 15 posts - 1 through 15 (of 66 total)
This is my interpretation of your puzzle to solve.
1. Create tables and populate data as in your Excel provided.
-- This temp table stores final result
IF OBJECT_ID('tempdb..#CustomerSpread') IS NOT NULL
drop table...
February 16, 2011 at 9:03 pm
I happened to find somebody who had similar issue as yours but I am not entirely sure if the solution he had would work for you.
This is web address: http://www.tek-tips.com/viewthread.cfm?qid=1455363&page=5
Good...
January 20, 2011 at 9:56 pm
Hi Doug, if you still have trouble, could you try my test script pls?
I did not seem to have problems in updating views on the fly using trigger in my...
December 8, 2010 at 5:04 pm
Hi
This is typical request to select top n in grioup by. If you use group by clause then you need to use cursor in while loop. But there is a...
March 17, 2010 at 3:44 pm
This was happened because your NT login created with default schema with your login other than dbo.
Try to varify what's in default_schema_name:
SELECT * FROM
sys.database_principals
where name like '%<your login>%'
See what...
November 19, 2009 at 9:50 pm
Are you looking for something like this?
Declare @sTest varchar(10)
Set @sTest='xxxxxxxxxx'
SELECT
CASE WHEN Len(Replace(@sTest,' ',''))=10 THEN 'CASE1'
WHEN Len(Replace(@sTest,' ',''))=9 THEN 'CASE2'
WHEN Len(Replace(@sTest,' ',''))=8 THEN 'CASE3'
END As [Result]
Set @sTest='xxxxxx xxx'
SELECT
CASE WHEN...
November 17, 2009 at 9:30 pm
Sim
To my knowledge SQL 2000 does not support
either
"Select * into #temp from exec(myDynamicSql)"
or
exec ('select * into #temp from ' + @sqlString)
But it supports
"Insert Into #tmp
exec (@myDynamicSql)".
However the condition...
January 23, 2008 at 2:26 pm
Hi James
I have spent some time to figure out what your environment is focused on table association. This is what I discovered.
1. tbKMQATarget has 3 FKs(FK tbKMQACustomer, FK tbKMQAMaterialSource, FK...
January 22, 2008 at 8:51 pm
Following my original suggestion means that you are using one DTS. Therefore you are not using the second DTS which had "oConn.Properties("DataSource").Value = sFilePath" in the ActiveX script.
Your question: what...
March 6, 2007 at 5:40 pm
Do some check in your trigger as follows:
Create Table [dbo].[ErrorCapture]
( [ErrDesc] Varchar(2000) Null)
Use the table inside the trigger as follows:
CREATE TRIGGER...
March 4, 2007 at 9:02 pm
I am not 100% sure that I understand what you are looking for. According to your code, you are doing through VB?? or in .NET???
My quiestion is are you...
March 4, 2007 at 3:06 pm
Try this in ActiveX Script Task:
Function Main()
Dim cn
Dim rs
Dim Flag
Set cn = CreateObject("ADODB.Command")
Set rs = CreateObject("ADODB.Recordset")
cn.ActiveConnection = "Provider=sqloledb;Data Source=Server;Initial Catalog=database;User Id=login;Password=password;"
cn.CommandType = 1 'adCmdText
...
March 1, 2007 at 5:56 pm
Unfortunately you may have to use temp table and cursor to capture the columns dynamically as below:
-- Declare local variables
Declare @SQLCommand Varchar(2000)
Declare @SelectString Varchar(500)
Declare @QueryString Varchar(2000)
Declare @AssessmentID INT
Declare @Coulmn Varchar(50)
Declare...
March 1, 2007 at 4:14 pm
I modified the code as below:
SET NOCOUNT ON
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[Alias]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[Alias]
if exists (select * from dbo.sysobjects where...
March 1, 2007 at 3:19 pm
Executes a scalar-valued, user-defined function, a system procedure, a user-defined stored procedure, or an extended stored procedure. Also supports the execution of a character string within a...
March 1, 2007 at 2:12 pm
Viewing 15 posts - 1 through 15 (of 66 total)