Solved

SSIS:  OLE DB Source object can't read columns of a EXEC SP that contains temp tables (Hash Table?)

Posted on 2008-06-23
5
831 Views
Last Modified: 2013-11-30
Hi All

SSIS - I am trying to insert the results of a ole db source/stored proc, into a ole db destination/table.
In the ole db source object, Connection Manager, I have SQL Command/ my SP typed out, and hitting the 'Preview' button shows the returned recordset as expected.

Problem:  In the ole db source object, Columns, no columns are visible.  

I have heard that this may be because I am using temp tables in my SP, that I have to replace them with 'hash tables', but I am not familar with these.

Question:  Does using temp tables cause problems in DTS/SSIS?  

Thanks in advance.
Jim
0
Comment
Question by:Jim Horn
  • 3
5 Comments
 
LVL 4

Accepted Solution

by:
zx10r earned 500 total points
ID: 21848642
make sure you have the following

SET NOCOUNT ON
SET FMTONLY OFF
0
 
LVL 4

Expert Comment

by:zx10r
ID: 21848704
SET FMT ONLY OFF
SET NOCOUNT ON
EXECUTE sp_ProcName

or you can add it directly in your procedure
0
 
LVL 65

Author Comment

by:Jim Horn
ID: 21848858
>SET NOCOUNT ON
Already had it.

>SET FMTONLY OFF
Wowwie, that works great.  Thanks.
0
 
LVL 4

Expert Comment

by:zx10r
ID: 21848905
I had the same problem a week ago. So yeah, i know how you feel =)
0
 
LVL 14

Expert Comment

by:Jagdish Devaku
ID: 21849000
Hi,

I think using of table variables will solve the issue.

So  replace the temp tables with table variables. (replace #temp table with @table variable)

all the best.

0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
I have a large data set and a SSIS package. How can I load this file in multi threading?
Via a live example, show how to shrink a transaction log file down to a reasonable size.
Using examples as well as descriptions, and references to Books Online, show the documentation available for datatypes, explain the available data types and show how data can be passed into and out of variables.

803 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question