Re: DTS and Temp Table

Tech-Archive recommends: Fix windows errors by optimizing your registry

From: Darren Green (darren.green_at_reply-to-newsgroup-sqldts.com)
Date: 04/04/04

  • Next message: Michael Vardinghus: "Re: Package calling another package"
    Date: Sun, 4 Apr 2004 10:23:46 -0700
    
    

    In message <OB2auPQGEHA.1228@TK2MSFTNGP11.phx.gbl>, Kevin Potter
    <temp@temp.com> writes
    >Hi,
    >
    >I am have a problem using a temp table in a stored procedure which is called
    >from DTS. Within the Transform Data Task Properties dialog the
    >Transformations for the Source does not display any fields. I know the
    >problem is caused by the temp table, what I want to know is there any work
    >around.
    >
    >Thanks!
    >

    Temp tables will work at run-time, but unfortunately it is virtually
    impossible to use them in the designer. There are two options to get
    round this-

    Change the proc to use a permanent table. Then change it back once
    design is complete.

    Change the source to something fixed, for example a simple select from a
    dummy table of the same structure that allows you to build the package.
    Then once built use Disconnected Edit to change the SQL back to the
    procedure.

    Basically the Designer needs something it can work with to get the
    required meta-data, but once you have finished designing you can change
    back to the real code, and the run-time will work as we know it should.

    Make sense?

    -- 
    Darren Green (SQL Server MVP)
    DTS - http://www.sqldts.com
    PASS - the definitive, global community for SQL Server professionals
    http://www.sqlpass.org
    

  • Next message: Michael Vardinghus: "Re: Package calling another package"

    Relevant Pages

    • Re: How to import fixed-width text file in MS SQL 2000?
      ... Most of people choose to loading the data from import file in to a temporary table then doing manipulation on that temp table, this way is useful when during the import progress, you could also maintain your database integrity. ... you could you DTS or SQL stored procedure. ... you have list of invoice need to be imported to invoice table every day. ... your stored procedure could be called any time you want, or it could be called from DTS and have it running in a defined schedule. ...
      (microsoft.public.sqlserver.server)
    • Re: how to create/use temp table on the fly?
      ... I agree with Tom that DTS is the way to go on this one. ... >I still think temp tables are not the route to go. ... >access to an Excel file. ... >data to an excel file on the fly and places each tab ...
      (microsoft.public.sqlserver.programming)
    • Re: SQLserver and the WHERE x IN y
      ... to a stored procedure - that would only work if you introduced subtyping into ... the temp table from the calling procedure (the temp table is still in scope, ... INSERT INTO #MyTempTable EXECUTE YourPopulateProc 123 ... INSERT INTO @MyTableVar VALUES ...
      (microsoft.public.sqlserver.programming)
    • Re: Stored Procedures in SE 7.3
      ... My end goal to write a stored procedure to be used by Lotus Enterprise ... Integrator (LEI). ... into temp t1; ... from bmdata, t1 ...
      (comp.databases.informix)
    • RE: Strange issue while executing sql server sp
      ... field is the one where truncation is occurring as my temp table field size is ... I have a simple stored procedure in sql server 2005 express version. ... ,finishdate datetime ...
      (microsoft.public.sqlserver.programming)