+ Reply to Thread
Results 1 to 3 of 3

MS Excel - SQL Data Query Connection to MS Project - Resources not displayed as one line

  1. #1
    Registered User
    Join Date
    07-23-2015
    Location
    Charlottetown, PEI
    MS-Off Ver
    2013
    Posts
    2

    MS Excel - SQL Data Query Connection to MS Project - Resources not displayed as one line

    I have the following code in External Data Connections for Excel: It retrieves the resources from MS Project and repeats the same task in the table for however many resources there are, which is what I don't want. How can I display all resources for the same task in one line from the SQL Query:

    For example:

    Current Display:

    Task______________Resource
    Prep Work____________Room A
    Prep Work____________Room B
    Prep Work____________Room C


    What I want is:
    Task_________________Resource
    Prep Work_______________Room A, Room B, Room C



    Code Is Outlined Below:

    SELECT DISTINCT P_ProjectDetails.Client AS 'Client',
    P_ProjectDetails.Product AS 'Product',
    T.[Project Reference] AS 'Project Number',
    A.ResourceName AS 'Resource',
    T.TaskName AS 'Task',
    T.TaskStartDate AS 'Start',
    T.TaskFinishDate AS 'Finish',

    T.[Lot Number],



    FROM dbo.MSP_EpmProject_UserView P,
    dbo.MSP_EpmTask_UserView T
    LEFT OUTER JOIN dbo.MSP_EpmProject_UserView P_ProjectDetails
    ON T.[Project Reference]=P_ProjectDetails.[Project Number]
    LEFT OUTER JOIN dbo.MSP_EpmAssignment_UserView A
    ON A.TaskUID=T.TaskUID

    WHERE P.ProjectUID=T.ProjectUID

    AND P.ProjectName = 'Operation Schedule of All Projects'
    --AND T.[Project Reference] IS NOT NULL
    --AND A.ResourceName NOT IN ('Unassigned Resource','Local Generic Resource')

    ORDER BY 1, 2

    http://www.msofficeforums.com/excel/...html#post87171
    Last edited by AKent; 08-20-2015 at 08:37 AM. Reason: Cross-post

  2. #2
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,447

    Re: MS Excel - SQL Data Query Connection to MS Project - Resources not displayed as one li

    Your post does not comply with Rule 8 of our Forum RULES. Do not crosspost your question on multiple forums without including links here to the other threads on other forums.

    Cross-posting is when you post the same question in other forums on the web. The last thing you want to do is waste people's time working on an issue you have already resolved elsewhere. We prefer that you not cross-post at all, but if you do (and it's unlikely to go unnoticed), you MUST provide a link (copy the url from the address bar in your browser) to the cross-post.

    Expect cross-posted questions without a link to be closed and a message will be posted by the moderator explaining why. We are here to help so help us to help you!

    Read this to understand why we ask you to do this, and then please edit your first post to include links to any and all cross-posts in any other forums (not just this site).

    http://www.msofficeforums.com/excel/...ection-ms.html

  3. #3
    Registered User
    Join Date
    07-23-2015
    Location
    Charlottetown, PEI
    MS-Off Ver
    2013
    Posts
    2

    Re: MS Excel - SQL Data Query Connection to MS Project - Resources not displayed as one li

    Link has been added. Please respond to question now.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 2
    Last Post: 05-15-2015, 04:12 PM
  2. How to query an Excel file in an External Data Connection
    By greyscale in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-11-2013, 01:06 AM
  3. Replies: 0
    Last Post: 11-14-2012, 03:52 PM
  4. Data connection issue (query not visible)
    By ppataki in forum Excel General
    Replies: 0
    Last Post: 03-06-2009, 05:02 AM
  5. Excel Query connection to Server Help...
    By ImtiazV in forum Excel General
    Replies: 0
    Last Post: 08-03-2007, 11:04 AM
  6. [SOLVED] project steps and resources template
    By Simo Sentissi in forum Excel General
    Replies: 0
    Last Post: 06-02-2005, 05:05 PM
  7. ADO connection/SQL query in Excel function
    By Steve in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-26-2005, 05:19 PM

Tags for this Thread

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1