Solved

SSIS OLEDB source editor

Posted on 2011-03-02
5
1,078 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

Zoho SalesIQ

Hassle-free live chat software re-imagined for business growth. 2 users, always free.

Question has a verified solution.

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

Why is this different from all of the other step by step guides?  Because I make a living as a DBA and not as a writer and I lived through this experience. Defining the name: When I talk to people they say different names on this subject stuff l…
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…
Viewers will learn how to use the INSERT statement to insert data into their tables. It will also introduce the NULL statement, to show them what happens when no value is giving for any given column.
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

863 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

18 Experts available now in Live!

Get 1:1 Help Now