How to pull the data from two different source into a destination?

  • Hi Friends,

    my process is OLEDB to OLEDB ...

    in the destination, i got a column name IMAGE..all the columns get data from one Db but data for this IMAGE column has to be pulled from a local disk....i used script component to pull these vaules....but i don't know how to combine this data with the OLEDB destination which has already got some source from another OLEDB...

    some one help me...Please ?

    Thanks,
    Charmer

  • Hi, is the IMAGE data on a separate SQL Server instance? Is it contained in a database or a flat file? Need more details...

    _________________________________
    seth delconte
    http://sqlkeys.com

  • just located in a local disk's folder...

    Thanks,
    Charmer

  • That's not any more details :). I'll have to assume that you have an image FILE on a disk. You can combine a select, insert, or update query with an OPENROWSET ad-hoc query to create a result from disparate sources, like this:

    select AddressLine1,

    (SELECT * FROM OPENROWSET(BULK 'c:\Capture.PNG',SINGLE_BLOB)as x) as ImageData

    from AdventureWorks.Person.Address

    Where AddressLine1 like '%990032%'

    _________________________________
    seth delconte
    http://sqlkeys.com

  • i could be able to pull the image records...

    the problem is i need to merge the data with another OLEDB source where both has no connection coulmn...

    i need is two columns from script component where im pulling image data...and remaining columns from OLEDB source into a OLEDB destination..

    i want to combine both source.....

    Thanks,
    Charmer

  • Using the ROW_NUMBER function you can order your first source data and second source data then you merge your data based row number.

  • not sure I'm clear on the problem, but if you are seeking to put two data streams together, a merge or merge join will accomplish this for you.

    Otherwise, since you are already using script component, any chance you can populate another output column with the needed data?

Viewing 7 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic. Login to reply