Results 1 to 3 of 3
  1. #1
    Join Date
    Sep 2005
    Posts
    240

    Unanswered: stored procedure with linked server

    Hi folks,

    I'm having a problem with the results of a stored procedure using a table from a linked server (Oracle).

    It seems not all of the data is returned from the field in the Oracle table, yet I know that the field in question is populated.

    I've tried altering the joins, changing the linked fields, swapping the order of the joins, but it still only returns some and not all of the data.

    This is the query from the procedure:
    Code:
        SELECT DISTINCT ld.Object_id, ld.Academic_year, ld.Course_Title, qc.COURSE_LEVEL
        FROM QUERCUS..QUERCUS.COURSE AS qc RIGHT OUTER JOIN
                dbo.Learner_Destination AS ld ON qc.DESCRIPTION = ld.Course_Title
        GROUP BY ld.Object_id, ld.Academic_year, ld.Course_Title, qc.COURSE_LEVEL
        ORDER BY ld.Course_Title
    At first I thought the values in the qc.Description field and ld.Course_Title field were different, but they are both the same.

    But still I can't get all the data from the qc.COURSE_LEVEL field.

    Has anyone encountered a similar problem with linked servers?
    <- Hides behind a rock.

  2. #2
    Join Date
    Jun 2004
    Location
    Long Island
    Posts
    696
    Have you tried just snapping the Oracle data to a temp table and working with it that way ? Not sure if you can snap the entire table or not (too large ?)

  3. #3
    Join Date
    Sep 2005
    Posts
    240
    Thanks for the suggestion.

    I ended up doing something similar.
    I remembered I had already taken some data out of Oracle and stored it in a table, since the data is related I just added the field on the end of that.
    <- Hides behind a rock.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •