Grain size curves and boring name references

Hello

Our grain size plot can show up to 7 test results.  When outputing grain size curves, there does not seem to be a limitation that you can only print results from one boring on the the curves in the way we have it set up.  You can select whatever tests you want, from multiple borings.  I would like to know how I can list the borings that are shown on the curve in the title block:  "Grain Size Curves for Borings X and X".  I tried putting <<POINT.PointID>> in the title block, but it only prints the first boring, not the others that might be part of the same plot.   What code should I use so that it can list the names of multiple borings that might be shown on the same plot.

Alternatively, can I do something in Page Properties that only allows one boring per page or per plot?

Thank you for your assistance.

Monique

  • No-one knows the answer to this?   I tried  <<Outputkeys>> but that lists both the boring name and sample numbers and I only want the boring names.   Then I tried this, which didn't work at all:

    <<Sql(_
      Select [POINT].[PointID] _
      From [POINT] _
      Where [POINT].[Pointid] In (<<OutputKeysInClause>>)_
    )>>

    Help!?

  • Hi Monique

    Our grain size plot shows up to 5 results. This may be changed in the XY GRAPH REPORT PROPERTIES

    If you want each graph report to only correspond to each boring, then change the following:

    In our legend, we have 5 lines to represent the 5 test results shown in the graph:

    When a graph report has more than one keyset fields  (PointID, Depth, etc) you need to use the Lookup and the DataSetKey functions to pull the correct data. So for the source column of my legend, the expression for the text is <<Lookup(<<LAB SPECIMEN.PointID>>,<<DataSetKey(<<#>>)>>)>> which looks up the point ID which corresponds to the DataSetKey.

    If you ever want to see what the <<DataSetKey(<<#>>)>> expression is, just put it as a text entity and look at the output.

  • Hello Paul - thank you for your reply.  I have no issues with printing the boring names and sample numbers at the bottom in the table.   Given that I can select multiple boring to print on the plot, I would like it to automatically (at the top of our output form) in the Figure title to indicate the borings that were selected and are showing on that form (e.g. GRAIN SIZE CURVES FOR BORINGS H-1 and H-2).  I could do this with a report variable where the title is manually entered, but I would prefer it to be automatic.  It seems like somehow gINT should be able to know what output is showing on that form and populate the boring names in the title.

  • There are 2 ways to approach this.  I will present both below.

    Method 1 - Brute force method

    As you noted, <<OutputKeys>> list both boring names and sample numbers (in my case sample depths) As shown in the first line of the example output below.

    It is important to realize that this is a comma delimited list. Each item in the list consists of a boring number and a depth separated by a vertical bar (pipe symbol). Thus, the brute force approach is to simply loop through the items in the list, separate the boring number from the sample depth using the pipe symbol as a marker, and add the boring number to a new list if it is not the same as the last item (generates a new list of unique boring numbers). The new list is then used to construct the desired output text. An expression to do this is presented in the code window below.

    <<Remark(Initialize all variables)>>_
       <<Let(NoKeys = <<ListCount(<<OutputKeys>>,",")>>)>>_
       <<Let(LastBoring = "XxXxXx")>>_
       <<Let(UniqueBoringList = "")>>_
    <<Remark(Start Loop)>>_
       <<Iterate(ItemNo,1,<<Get(NoKeys)>>,1," ",_
         <<Let(CurrentKey = <<GetListItem(<<OutputKeys>>,",",<<Get(ItemNo)>>)>>)>>_
         <<Let(CurrentBoring = <<Left(<<Get(CurrentKey)>>,<<Calc(<<InStr(<<Get(CurrentKey)>>,"|")>>-1)>>)>>)>>_
         <<IIf(<<Get(CurrentBoring)>> <> <<Get(LastBoring)>>,_
           <<Let(UniqueBoringList = <<ListBuildSepTrim(", ",<<Get(UniqueBoringList)>>,<<Get(CurrentBoring)>>)>>)>>_
         )>>_
        <<Let(LastBoring = <<Get(CurrentBoring)>>)>>_
       )>>_
    <<Remark(End Loop)>>_
    <<Remark(Assemble Output String)>>_
       Grain Size Curves for Borings: <<Get(UniqueBoringList)>>

    An example of what this expression outputs is shown in the second line of of the picture above.  Note that it prints a list of unique borings selected during output. If you select more than number of curves allowed per page (you noted that yours was set to 7) it does not show borings that are on the current page, rather, it shows all borings that were selected for the report (some of which would be shown on subsequent pages of the same report). There are many ways to write this expression and others may have better suggestions.

    Method 2 - <<ReportPointIDList>> Data item

    While documenting Method 1, I came across a data item that I was unaware of, <<ReportPointIDList>>. This data item generates a list of unique PointID's actually output to the report. The results of this data item are shown on the third line of the example output shown above. It is much closer to what we actually want except it has single quotes around each boring and no space following each comma.  That is simple enough to fix by just replacing each single quote in the generated text string with nothing, and each comma with a comma followed by a space. The expression to do this is in the code window below.

    Grain Size Curves for Borings: _
    <<Replace(<<ReportPointIDList>>,True,False,_
      "'","",_
      ",",", "_
    )>>

    Be careful with the commas, double quotes and single quotes. The output from this expression is shown on the 4th line of the example output provided above.  It is the same as generated by Method 1 and has the same limitations but it is a more elegant solution.

    I have not tested these expressions extensively, they seem to work for my test project and data structure on my grain size graph template (which is pretty standard). Yours may be different.

    Note that both of these expressions can be combined with a HasData function that checks a report variable for data and uses it if it is there, else use this expression.  This allows you to have a report variable that you could manually enter the title for the report on. If none is supplied it would default to this expression.

    If this is not what you are seeking, please clarify your request. I am traveling and may not be able to respond promptly. Patience and I will get to it.

  • Mr. Zang - you are a genius.  Thank you so much for this solution. The 2nd version worked perfectly for me.