

To do this, we are going to create a new formula, and name it UpperCase.
Crystal security test results how to#
Now let's learn how to combine those fields AND use a function to turn the fields into uppercase. In the last section of this article, we combined two fields using a formula. However, you can use formulas for strings. In fact, they're very handy when building a report in Crystal Reports. We don't often think about formulas as they relate to text – or strings. When most of us hear the word formula, we automatically think of numbers and math. The space is now added between the first and last name in our report.
Crystal security test results plus#
This tells Crystal Reports to add a space.Įnter another plus (+) sign to join the space to the second report field. Right click on the formula field, then select Edit.Īfter the plus (+) sign, add open quotation marks, hit the spacebar, then add closing quotation marks. Now double click on the report field that you want to combine with the first field that you already added.ĭrag the formula field from Field Explorer to your report.Īs you can see in our report above, the fields are combined. However, there the first and last names run together. There isn't a space between them. However, if you want, you can use an ampersand (&) instead. Since we are adding two fields together, we are going to enter a plus (+) sign. In the section of the dialogue box that contains the report fields, double click on the first report. To do this, go to Field Explorer and create a new formula field. You can also use formulas to concatenate the values in multiple fields – or combine the data in multiple fields.Īs you can see, the first names and last names for our customers are in two separate fields. If you still want to delete the formula field, click Yes. You will then see a message that lets you know that if you delete the field, it will also be removed from your report. To delete a formula field, go to the Field Explorer panel. Select the formula field, right click, then select Delete. If you want to change the formula that calculates the data in the formula field, select the formula field in Field Explorer. Right click, then choose Edit. Type in the new name for the formula field. The field will then open so that you can edit it. If you want to rename a formula field, right click on the formula field in Field Explorer.

The formula field then appear in our report:Ĭhanging, Renaming, and Deleting Formula Fields To place the formula field in the report, go to Field Explorer and drag the formula field just as you would any other field in your report. Once our formula is finished, we are going to click Save & Close. Now we double click on the NumberPieces field to add it to the formula. We want to divide this field by the number of pieces sold. To divide, we add the symbol for division. You can now see this field in the white area where we will build the formula. To do this, in the Formula Workshop, we are going to double click the Sales/Year in the section of the Formula Workshop that contains our report fields. We will do this by taking the Sales/Year field and dividing it by the NumberPieces field. Now, we want to build a formula that will tell us the average amount spent per product in the report below. The final section is the empty white area on the Formula Workshop. This is where you build formulas. The next section contains mathematical operators. The data fields in your report are shown in the section circled below. You can see that our new formula field is selected. The Formula Workshop is divided into five areas. You will then see the Formula Workshop dialogue box. Right click on Formula Fields, then select New.Įnter a name. We will call ours AvgMoSales. To add the formula field, go to the Field Explorer panel. Of course, we will use the Sales/Year field, which is the sales for the entire year, to calculate the average monthly sales. This new field will be a formula field, and it will contain the average monthly sales. We want to add another field in this report that will come after Sales/Year field. In Crystal Reports, you can use a formula to calculate a piece of data. That data is then inserted into your report. In this article, we are going to focus on learning all about formulas, starting with the basics and moving into the more advanced.
