temp-table

Datasource returned from Informix Stored Proc

I have an Informix stored procedure that returns two columns and multiple rows. I can use "EXECUTE FUNCTION curr_sess(2009,'SP')" fine, but how do I get the results into a temp table. EDIT: We are on version 10.00.HC5 Testing Jonathan Leffler's idea didn't work. EXECUTE FUNCTION curr_sess(2009,'SP') works fine. Then I did CREATE...

What are the concerns of having Temp/variable tables inside a view?

a friend of me is asking if i know any reasons why he should not included Temporal or variables tables inside a View in SQL-Server 2000. i could only think that a new table will be created everytime the view is accessed but i am wondering is there are any other concerns. Thanks, EDIT: This is not Possible ...

Can a return statement prevent a using statement from closing a connection to a database?

When I'm creating temp tables I get an error message telling me that the temp table already exists. The temp table is unique to the session so it seems my connection isn't closing properly and I think it may have something to do with a return statement I have in my using statement. I have the following code: using (IDbConnection connec...

Is it safe to put an index on an Oracle Temporary Table?

I have read that one should not analyze a temp table, as it screws up the table statistics for others. What about an index? If I put an index on the table for the duration of my program, can other programs using the table be effected by that index? Does an index effect my process, and all other processes using the table? or Does it e...

recommend a good temp table tutorial in SQL Server

Hello everyone, I searched but cannot find a good temp table usage tutorial for a newbie in SQL Server 2005/2008. I want to learn pros and cons of temp table compared with normal table, its life time and how temp table is shared (in the same session, cross sessions)? thanks in advance, George ...

Creating a Primary Key on a temp table - When?

I have a stored procedure that is working with a large amount of data. I have that data being inserted in to a temp table. The overall flow of events is something like CREATE #TempTable ( Col1 NUMERIC(18,0) NOT NULL, --This will not be an identity column. ,Col2 INT NOT NULL, ,Col3 BIGINT, ,Col4 VARCHAR(25) NOT NULL, ...

Looking for an efficient way to pass a collection parameter to a SQL Stored Procedure

Hi, I need to pass a collection of objects as a parameter to a stored procedure. Initially, I thought of serializing this collection and passing it to the procedure as a xml string. Then, inside the procedure, I'd use XML to get the data from the string parameter and use it. But I thought this approach was not performatic at all. I wa...

Recordset manipulation in SSIS

In my SSIS job, I have a need to accumulate a set of rows and commit them all transitionally when processing has completed successfully. If this was pure SQL, I would use a temp table inside a transaction. In SSIS there are a number of issues complicating this. It's difficult to have multiple components share the same transaction and hav...

What does 'select to a temp table' mean?

This answer had me slightly confused. What is a 'select to a temp table' and can someone show me a simple example of it? ...

Dealing with MySQL Temp Table algorithm for views

It would be nice if the Temp Table algorithm would be renamed to Unscalable algorithm. Perhaps then it would provide more of a warning to developers when seeing this in a view definition - similarly when it says using temp table in the explain results. Just a tongue-in-cheek request for the most part but really it can be disastrous to t...

Insert into temp table from stored procedure generating distributed transaction error in SQL 2000

Similar to Insert into a temp table from a stored procedure on Sql Server 2000 from last year, but now with a strange error. I'm using Microsoft SQL Server 2000 to dump results from one stored procedure into the temp table of another procedure. Both procedures are on the same physical server, yet I'm getting an error message as if the s...

[SQL Server] There is already an object named '##Temp' in the database.

I have a stored procedure on SQL Server 2000. It contains: select ... into ##Temp ... ... drop table ##Temp When I run the stored procedure with ADO a second time, it prompts: There is already an object named '##Temp' in the database. Could anyone kindly tell me what's wrong? ...