Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 scope of #table in a dtsx

Author  Topic 

AAAV
Posting Yak Master

152 Posts

Posted - 2010-03-12 : 11:27:59
if i create a temp table in the first step of the dtsx will it be available for the full run?
what is the scope?

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2010-03-12 : 11:32:45
you need to set "retain same connection" property to "true" for the connection that is used to create the temp table, and then use that connection for all the cases where you want to have references to the created table.

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page

AAAV
Posting Yak Master

152 Posts

Posted - 2010-03-12 : 12:58:04
not able to locate it???
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2010-03-12 : 12:58:42
welcome

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2010-03-12 : 13:04:27
quote:
Originally posted by AAAV

not able to locate it???


why?

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page

AAAV
Posting Yak Master

152 Posts

Posted - 2010-03-12 : 13:31:45
I went to the connection in the connection managers window... double clicked it ot see the propery... i dont see anything like what you said.
What am i doing wrong?
Go to Top of Page

russell
Pyro-ma-ni-yak

5072 Posts

Posted - 2010-03-12 : 14:50:26
in the connection properties

Go to Top of Page

AAAV
Posting Yak Master

152 Posts

Posted - 2010-03-12 : 16:40:22
Thanks i missed it
This my query
Select
A.[state],A.[vc_trimid] ,
A.[interval],SUM_of_Total_Cost,B.Year,b.Make,b.series,b.body_style_name,b.trans,b.destination,
b.msrp_adj,b.invoice_adj,b.city_fuel,b.highway_fuel,b.date,b.time
FROM [Maintenance_work].[dbo].[#temp1] A INNER JOIN [Vinbase_dev].[dbo].[data_input_master_export] B on
A.vc_trimid=B.vc_trimid
And i still get the error saying
"Invalid Objectname #temp1"
how do i insert pictures here?
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2010-03-13 : 00:57:26
quote:
Originally posted by AAAV

Thanks i missed it
This my query
Select
A.[state],A.[vc_trimid] ,
A.[interval],SUM_of_Total_Cost,B.Year,b.Make,b.series,b.body_style_name,b.trans,b.destination,
b.msrp_adj,b.invoice_adj,b.city_fuel,b.highway_fuel,b.date,b.time
FROM [Maintenance_work].[dbo].[#temp1] A INNER JOIN [Vinbase_dev].[dbo].[data_input_master_export] B on
A.vc_trimid=B.vc_trimid
And i still get the error saying
"Invalid Objectname #temp1"
how do i insert pictures here?


try not prefixing the db schema

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page
   

- Advertisement -