Graphic Column from fields in two different tables

I've looked around the forum and wikis etc. and can't figure out how to do this for some reason, although it seems simple enough to me. Probably just my lack of understanding the various functions that are available. 

I'm trying to make a graphic column (Column - Graphic Column, not an individual body entity Graphic Column) in a log report showing the symbol for the soil/rock type. I have one table for soil component descriptions, and a different table for rock component descriptions.  Each table has a Graphic field, i.e. <<SOIL DESCRIPTION.GRAPHIC>> and <<ROCK DESCRIPTION.GRAPHIC>>. Both of these fields use the Graphic!matl lookup list.  Each table also has Depth and Bottom fields for the top depth and bottom depth. 

How do I get the column to use both of these tables and the appropriate fields in the Top Depth, Bottom Depth, and Fill Type properties? Do I just need to use 2 columns?  (Previously our log report used 2 individual body entity graphic columns with the same X value to accomplish this)

Thanks for any help!

Parents
  • Hello,

    For your situation, I believe you will need to keep using 2 columns.  Otherwise, you would have to write a complex SQL expression.  Almost anytime the data is coming from 2 different tables you will run into this problem.  

    By they way, text columns and text vs depth entities do have an option for data coming from different tables, and that is to use the Second Text Spec tab for the second table.



  • Hello,

    I did manage to find a way to get both tables into the same graphic column.  I entered the Top Depth Expression as:

    <<Depth>>

    and the Bottom Depth Expression as:

    <<FirstData(<<SOIL DESCRIPTION.Bottom>>,<<ROCK DESCRIPTION.Bottom>>)>>

    and entered the Fill Type[!Symbol] as:

    Matl!<<FirstData(<<SOIL DESCRIPTION.Graphic>>,<<ROCK DESCRIPTION.Graphic>>)>>

    and it works.  I found this solution in an odd place, under the gINT Help entry for Variable Legend Entity Overview, near the end of the entry. Since I was also trying to get a Graphic Text Doc to show all of the material symbols in a single Variable Legend Entity, rather than in two entities (1 for soil and 1 for rock) as they currently are, this was serendipitous. However, now I can't figure out how to get a single variable legend entity to work. I tried entering the above FirstData expression under "Field with Data," but no dice.  It's not a big deal I guess, and might be impossible since this is a separate Graphic Text Doc and not on the Log report. 

    Thanks again for your help. 

    Answer Verified By: SH14277 

  • Hello,

    Actually, that is a better way than using Second Text Spec.  



  • Hi again,

    I'm not quite ready to give up on getting the Graphic Text Doc to show the lithology symbols from both tables (SOIL DESCRIPTION.Graphic and ROCK DESCRIPTION.Graphic) in a single Variable Legend Entity - do you have any ideas about how to accomplish this?  I did try the above FirstData function which worked within my Log report but it does not work for the Graphic Text Doc legend.

    The closest I can get to what I want is to make 2 entities, with the Rock graphics output at a conditional Y value based on a calculation of how many rows of Soil graphics there will be.  I would prefer to have the Rock graphics start on the same line where the Soil graphics end.  

    Might still be a lost cause but thanks for looking anyway!

  • Yes, you are correct, the Field With Data field does not work with anything but <<TABLE.Field>>.  Using a conditional Output Override Y for the rock graphics is the way to go.  It will take an SQL to get it to start where the soil graphics end.  Do you need help with writing the SQL?  Normally we don't offer to help with SQLs, but I have an expression that could easily be adapted to work here.



  • I don't know how to write SQLs so if you have something that is easily modified, that would be very helpful if only for my own learning process.  I would like to learn more about SQL so I can write some gINT Rules that I have yet to figure out.

    I did get the following to work OK for what I'm looking for, just using the actual vales of Y, number of columns, and row height for the Soil graphics and setting up the Output Override Y for the Rock graphics to do the arithmetic:

    <<Calc(7.2 - ((<<Int(<<Calc(<<CountUnique(<<SOIL DESCRIPTION.Graphic>>)>> / 4)>>)>> + 1) * 0.35))>>

    (7.2 is the Y value for where my Soil graphics start

    I have 4 columns of soil graphics

    My soil graphics rows are vertically spaced at 0.35)

    This puts the Rock graphics starting right below the last row of soil graphics, even if it is a partial row. For a partial row it looks OK to me, I'm not too picky.

    Thanks again!

Reply
  • I don't know how to write SQLs so if you have something that is easily modified, that would be very helpful if only for my own learning process.  I would like to learn more about SQL so I can write some gINT Rules that I have yet to figure out.

    I did get the following to work OK for what I'm looking for, just using the actual vales of Y, number of columns, and row height for the Soil graphics and setting up the Output Override Y for the Rock graphics to do the arithmetic:

    <<Calc(7.2 - ((<<Int(<<Calc(<<CountUnique(<<SOIL DESCRIPTION.Graphic>>)>> / 4)>>)>> + 1) * 0.35))>>

    (7.2 is the Y value for where my Soil graphics start

    I have 4 columns of soil graphics

    My soil graphics rows are vertically spaced at 0.35)

    This puts the Rock graphics starting right below the last row of soil graphics, even if it is a partial row. For a partial row it looks OK to me, I'm not too picky.

    Thanks again!

Children