Having SQL trouble efficiently connecting asset table fields.

I have created the following custom assets. . .
The data I need is in AD_11.FIELD_10068. What is needed depends on the selection of AD_16.FIELD_10044.
AD_16.FIELD_10044 is presented to the user, via a single select custom field in a ticket .
Depending on the selection, I look to AD_16 fields - FIELD_10062, 63, 64, 65, 66. To get the correct result from AD_11.FIELD_10068 I join the matching text in AD_16 fields to AD_11.FIELD_31. A simple query, for one of the AD_16 fields runs very quickly. For example -

    ASSET_DATA_16.FIELD_10042 AS Program_number,
    ASSET_DATA_16.FIELD_10043 AS Status,
    ASSET_DATA_16.FIELD_10053 AS Media_Center,
    RPM.FIELD_10068 AS Reg_Prgm_Mgr
GROUP BY Program_number

returns what I am after very quickly.

I can add one more of the AD_16 fields and corresponding join to this query and it runs satisfactorily but, trying to query for any more fields or all five fields at the same time runs on and on. There are instances where only 2 or 3 of the AD_16 fields have data but, I need to query all 5 fields every time.

Any help would be most appreciated. I have other questions around these asset tables but this one is urgent and I need to get it resolved ASAP.

0 Comments   [ + ] Show comments

Answers (1)

Answer Summary:
Posted by: jmarotto 3 years ago
Fourth Degree Green Belt

Top Answer

See - http://www.itninja.com/question/trouble-connecting-the-sql-dots
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ