Posts by Vijetha

    I have excel setup with SQL connection. I have a column A named as 'Ref' and column B named as 'Source' with formula

    =IF(TRIM(A2)="TR","Training",IF(TRIM(A2)="IL","Internal Labor",IF(TRIM(A2)="CO","Commissions",IF(TRIM(A2)="TC","Third Party Costs",""))))

    So column B 'Source' gets submitted to SQL.

    So when the column A 'Ref' is blank, then the user will update values in column B manually.

    Everytime the excel is opened, the manually entered data is getting blank, due to the else part of formula in the end i.e. ",""))))

    I changed the formula with 'A2' instead of "" as shown below.

    =IF(TRIM(A2)="TR","Training",IF(TRIM(A2)="IL","Internal Labor",IF(TRIM(A2)="CO","Commissions",IF(TRIM(A2)="TC","Third Party Costs", A2))))

    But this give me an error saying "There are one or more circular references where a formula refers to its own cell either directly or indirectly. This might cause them to calculate incorrectly. Try removing or changing these references, or moving the formulas to different cells".

    How can I change the formula so that I can stop getting the cell blank every time the excel is open ?