Solved

SSIS OLEDB source editor

Posted on 2011-03-02
5
1,075 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
  • 2
  • 2
5 Comments
 
LVL 17

Accepted Solution

by:
Barry Cunney earned 250 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 250 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

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Suggested Solutions

International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
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…
Via a live example, show how to extract insert data into a SQL Server database table using the Import/Export option and Bulk Insert.
This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function

762 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

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now