?
Solved

SSIS OLEDB source editor

Posted on 2011-03-02
5
Medium Priority
?
1,094 Views
Last Modified: 2012-05-11
IN ssis OLEDB source editor, under sql command text. I have a  T-sql like below. Nothing wriong with sql syntax, but when I click at columns only on my first query column are available, then when I try to produce results again only on my first query results are presented. Any advise to get this work in ssis OLEDB ?

select name,add,phone, Count(*) from tabletest
go
select * from tabletest where date_time='2011-0-01'
0
Comment
Question by:motioneye
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 17

Accepted Solution

by:
Barry Cunney earned 1000 total points
ID: 35016524
Hi Motioneye,
not sure if you can have 2 SQL statements as the SQL for the OLEDB source.
It does not really make sense

If you need several SQL statements to arrive your final result set then maybe put the statements in a Stored Procedure and do exec <sp_Name> in the on the OLEDB SQL command entry
0
 

Author Comment

by:motioneye
ID: 35016623
I did try with stored procedures, it still show me same results.. do you have any idea how to work on this ?
0
 
LVL 15

Assisted Solution

by:derekkromm
derekkromm earned 1000 total points
ID: 35016811
Like BCUNNEY said, it doesn't make any logical sense.

You can only return a single result set at a time.

The only way something like that would work is if they had the same columns and you unioned the 2 statements together.

If you explain what you're logically trying to do w/ both statements, we may be able to find a workaround for you by re-writing the T-SQL.
0
 
LVL 17

Expert Comment

by:Barry Cunney
ID: 35017486
Yes as derek has said, we need to know more about what you are trying to achieve, so the more information you can give about the purpose of what you are trying do in SSIS, the better overall solution and advice we can give you
0
 

Author Closing Comment

by:motioneye
ID: 35018787
Hi,
Just had workaround on it, tq for your guys support
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

A Stored Procedure in Microsoft SQL Server is a powerful feature that it can be used to execute the Data Manipulation Language (DML) or Data Definition Language (DDL). Depending on business requirements, a single Stored Procedure can return differe…
When trying to connect from SSMS v17.x to a SQL Server Integration Services 2016 instance or previous version, you get the error “Connecting to the Integration Services service on the computer failed with the following error: 'The specified service …
Using examples as well as descriptions, and references to Books Online, show the documentation available for date manipulation functions and by using a select few of these functions, show how date based data can be manipulated with these functions.
Using examples as well as descriptions, and references to Books Online, show the different Recovery Models available in SQL Server and explain, as well as show how full, differential and transaction log backups are performed

719 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