Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Step 1: "Dataset Information"

  1. Set the name of the reportdataset
    1. This name must be unique to the other datasets
    2. Name the dataset something descriptive so you have an idea of what kind of information is included just by looking at the name
  2. Add a description of the dataset
    1. This description is required
    2. The description allows you to give more detail about the dataset than you are able to give in the shorter title
  3. The "Created By" field displays your username to show who is the creator of the dataset
  4. The "Distinct" check box will remove duplicate records from the dataset if checked
    1. This option is useful if you are trying to build a dataset that has duplicate records and you need only one record for each value
      1. Example: a listing of years where applications were filled out
  5. The Share level option will allow you to choose who is able to view this dataset
    1. Private: Only the creator
    2. Group: Shows a multi-select check box to allow you to choose which employee groups are able to view the dataset
    3. Other Users: Everyone with a valid account
    4. Public: Everyone with access
  6. The "Overwrite" option will allow you to overwrite an existing dataset with the version that you are going to create
    1. When a dataset is included in a report or another dataset, this option will be unavailable since changing the dataset may break the report or dataset that depends on it

...

There are four different options available to choose from in the drop down. For this example, we will assume that I am joining the permitappfieldcustomoptions table (which is used to join the PermitApps and parcel records table) and the parcel records table. Depending on the option that is chosen in the drop down, there will be different information pulled into the dataset

Only matching recordsIf "Only matching records" is chosen, the dataset will only display applications that have a parcel record associated with it.
Image Modified


appidParcel number
123134234564
321123456789
456567856765
890098897678


All from leftIf "All from left" is chosen, the dataset will display all applications whether or not they have a parcel number associated with it.

Image Modified


appidParcel number
123134234564
321123456789
456
890


All from right If "All from right" is chosen, the dataset will display all parcels whether or not they have an application associated with it.
Image Modified


appidParcel number
123134234564
321123456789

567856765

098897678


All records

If "All records" is chosen, the dataset will display all applications and all parcels

Image Modified


appidParcel number
123
321123456789
456567856765

098897678



Once you have chosen one of the options from the drop down, you can choose which fields from each table to make the join on. When you first click the green plus symbol, it will default to joining the tables where a certain value in the table on the left of the join is not blank.

...

The Simple conditional field is used to check the value of a single field and output a value that is determined by the contents of the value of that field. For example, I could set up a conditional field to display a field in the dataset that either displays "Yes" or "No" based on whether or not the application is approved. I could set it up so that if the "statusname" field is equal to "Approved", it will output "Yes" for that record and if it is equal to anything else, it will output to "No".

appidStatus NameYes or No
123ApprovedYes
321CanceledNo
456Pending ReviewNo
789ApprovedYes

The Simple option is used by selecting the "Simple" option to the right of the "Alias" text box. Once you make the selection, the template for the conditional field will appear.

...

With this setup, any applications that were completed before 2018-04-20 will show "Before", any that were completed after 2018-04-20 will show "After", any that were completed on 2018-04-20 will show "On", and all other applications will return "N/A".

appidDatetime CompletedDate On/Before/After
1232018-01-01 09:38:00Before
3212018-04-20 15:01:00On
4562018-09-30 07:19:00After
789
N/A

Step 7: "Formatting"


OperationUseRequirementsOperation Format
CoalesceReturns the value of the first field in the listing that isn't null/emptyTwo or more fields

ConcatenateReturns two or more fields formatted together as one fieldOne or more fields

CurrencyReturns a number formatted as a dollar valueA field containing a numeric value

Date FormatReturns the date provided in a format specified in the formulaA field containing date data

Date OnlyReturns only the date portion of a datetime fieldA field containing a date

Date PartReturns a portion of the provided date as specified in the formulaA field containing a date

Epoch to DatetimeReturns a datetime value converted from an epoch value(the number of seconds since January 1, 1970 not counting leap seconds)A field containing a numeric value (Must be an epoch value to function correctly)

JoinReturns a listing of values associated with a single value (Explained below)A field and a separator value (space, comma, semi-colon, etc.)

LeftmostReturns a number of the leftmost digits of a field as specified by the second value of the formulaAny field

NumberReturns a number field converted from a text datatypeA text field containing a number

RightmostReturns a number of the rightmost digits of a field as specified by the second value of the formulaAny field

Text to DateReturns a date field converted from a text datatypeA text field containing a date

Text to DatetimeReturns a datetime field converted from a text datatypeA text field containing a date

...

Info
titleThe Join Operation

The Join operation is different that the original join step in the dataset creation and is a tricky one to fully master. It requires a decent understanding of the data that you are trying to manipulate. The example below will try to explain the intricacies that come with using the Join operation using a real-life situation within OneGov.

Example: Multiple Parcels per Application

One often requested report is one that will show certain important pieces of information associated to an application. This may include the Applicant's name, the location of the work being done (parcels), and certain custom fields in the application. In some applications, the application is able to select multiple parcels on a single application. If a dataset was created to show the appid and the parcel number for that application by choosing the appid and parcel columns on the field step, there would be multiple rows that have the same appid but different parcels. This could possibly throw off the report if you were counting the number of rows to see how many applications there are in the report.

appidParcel Number
123123456789
123987654321
456

321987654

This problem can be solved by using the join function. Instead of choosing both the appid and parcel number on the field step, only the appid would be chosen. On the "Formatting" step, a join operation would be added by naming the field appropriately (in this case "Parcel Number") and then choosing the parcel number column and adding that to the first box in the formula and inserting a comma with a space after (so the parcels are separated a bit) in the second box using the manual input. This operation is then added to the dataset by clicking the green plus on the left side of the field builder.

By setting up the dataset in this manner, the results now show that there were only two applications and not three.

appidParcel Number
123123456789, 987654321
456321987654



Step 8: "Filter"

This step allows you to filter out more information from the dataset. You can create a filter by choosing a field from the tables that you included in the dataset in step 2. Once you click on one of the field names, it will appear in the space below the listing of tables. A drop down next to the field name will allow you to choose from several different ways to filter the dataset based on the data type of the field you chose. Once you choose how to filter the field, you can type a value into the text box to filter on that value. Once the filter is built, you can click the green plus in the top left of the filter box to add the filter to the dataset. If you accidentally click the wrong field to filter on, you can click the broom icon in the top left to clear the selection. The filter step allows you to include multiple fields in a single filter as well.

...