Jump to content

Search the Community

Showing results for tags 'formula'.

More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • Caspio Bridge
    • General Questions
    • Caspio JavaScript Solutions
    • Tables, Views and Relationships
    • Import/Export and DataHub
    • DataPages
    • Deployment
    • Security, Authentications, Roles, SAML
    • Styles and Localizations
    • Parameters
    • API and Integration
    • Calculations and aggregations
    • User JavaScript and CSS Discussions

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start




Website URL






Found 10 results

  1. Hello Community, I´m new to Caspio and my try, to use a calculated field in a table ends with an error (see Screenhot here: http://prntscr.com/cxgbw8) in the formula: Invalid formular: Incorrect syntax near PERSISTED I´ve used this formular DateDiff(year, [@field:P_DOB], GetUTCDate() as it is shown in the help section (http://howto.caspio.com/faq/reports-datapages/calculated-fields-and-datediff-function/). Any ideas about my wrong usage? Thanks for your comments!
  2. I understand we are not able to use the date formula for day of the week directly in a table field. I have managed to create a calculated field in a DataPage that uses a day of the week formula (see below for the formula used) which is working nicely and gives me the desired result on the DataPage. However, this is good for display only and I cannot use the result other than viewing it on the DataPage. Is there a way to pass the result from my DataPage calculated field back to a table (same table that the DataPage is connected to)? Or, is there anyway to get a working formula directly on the table that provides a number 1 through 7 for day of the week for a given date? The formula I am currently using on the DataPage and works well is: DatePart(dw,[@field:XXXXX])
  3. Hi, Didn't exactly know where to put this one, so sorry if this is in the wrong place. I'm new to Caspio so perhaps this is a noob question, but please help me out and thanks for reading anyway I've got a table which has a couple of date fields for the weekdays. A workday starts on monday and the user can select which mondayDate that is . I would like to add the date of monday + 1 day to the field TuesdayDate and so on for the other days. So if a user selects 01 januari 2017 as date for monday, the field TuesdayDate = 2 januari 2017 etc. I thought i could do that via a tabel/formala field where TuesdayDate = DATEADD (dd , 1, [@field:MondayDate] ) but when i use this the formula field doesn't show up any more in my Submission DataPage. So perhaps via a triggered action, where i used an insert and update action when the field MondayDate is not empty then fill the TuesdayDate as the value of Monday + 1 day. But i'm doiing something wrong cause when i validate no problem but when i try to enable this i get an error concerning nesting level 1. Do you have any idea how to approach this ? I added a screenshot of the triggered action Thanks Bart
  4. Hello. I am trying to sort out the capabilities of the new formula data type in v9.4. I'd like to combine text fields and a date field in the formula but I get an invalid formula error when just combine the fields with a "+ Str(1)+". Do I need to convert the date to a string? Also, the formula seems to reference the stored value of a foreign key in the table. Is there a way to use the display value of a related field instead? Thank you.
  5. I have a table with a field named Total_Time with a function datatype, that calculates total time using the flowing formula.. Round(((([@field:End_Hour] - [@field:Start_Hour]) * 60 + ([@field:End_Min]-[@field:Start_Min])) - (([@field:Break_Fin_Hour] - [@field:Break_Start_Hour]) * 60 + ([@field:Break_Fin_Min]-[@field:Break_Start_Min]))) /60 ,2) This works as expected… Now I would like to add a conditional statement that checks the value of the field "Assigned_Tech" and if the value is “Summary” then leave the Total_Time field blank, else run the formula. Im thinking.. CASE IF ([@field: Assigned_Tech])!==”Summary” THEN Round(((([@field:End_Hour] - [@field:Start_Hour]) * 60 + ([@field:End_Min]-[@field:Start_Min])) - (([@field:Break_Fin_Hour] - [@field:Break_Start_Hour]) * 60 + ([@field:Break_Fin_Min]-[@field:Break_Start_Min]))) /60 ,2) END Can someone please help me with the correct case statement to use. I spent 2 days writing the total_time formula and now am in a bit over my head using conditional statements in the formula. Thanks in advance for any an all help
  6. I have a table in which there is a field that a part of the value in this field needs to be extracted and saved in another column. How can I achieve this? The value always starts with: CG: and it can be in the middle where it ends with "," or the last value For instance: GG:American Value Entered, CG:Startup, MG:Advanced or GG:American Value Entered, CG:Startup
  7. I've created a few formulas and now require a field that uses some of the existing formula values in a calculation. Is there a way I can create a new formula similar to the following: [@field:Formula1] / [@field:Formula2] Reference: http://howto.caspio.com/tables-and-views/data-types/formula-fields/ "Other Formula Fields Not Compatible" Hoping for a way around this.... Thanks
  8. How to perform multiple consequential functions using Formula DataType? I want to replace multiple characters from a TextField (TITLE) using Formula DataType functions. Let’s Say TITLE = DESK!TO$P AND desired outcome = DESKTOP Replace([@field:TITLE], '!', '') AND Replace([@field:TITLE], '$', '') INVALID THE "CASE, WHEN THEN" STATEMENT PERFORM THE FIRST TRUE STATEMENT ONLY
  9. Hello, I am trying to do a function to remove and replace some special characters from a text field using formula DataType, However, how can I remove the apostrophes (') Here is the formula (Last one with apostrophe) CASE WHEN Charindex('!',[@field:TITLE],0) <> 0 THEN Replace([@field:TITLE], '!', '') WHEN Charindex('#',[@field:TITLE],0) <> 0 THEN Replace([@field:TITLE], '#', '') WHEN Charindex(':',[@field:TITLE],0) <> 0 THEN Replace([@field:TITLE], ':', '') WHEN Charindex(''',[@field:TITLE],0) <> 0 THEN Replace([@field:TITLE], ''', '') END
  10. Hello, I'm having difficulty with my time formula for a specific scenario. It is working correctly but producing too much time in some instances. I'm using a calculated field with the following formula to find the total time worked each day: cast (Datediff(hour, [@field:Start_TIme], [@field:End_Time])%24 as varchar)+' hours,'+ cast (Datediff(minute, [@field:Start_Time], [@field:End_Time])%60 as varchar)+ ' minutes' The formula is working when: The time calculated is more than an hour (i.e. 2:00 PM to 4:45 PM) = 2hrs, 45 minutes (CORRECT RESULT) or The time calculated is less than an hour but within the same hour of the day (i.e. 2:00 PM to 2:23 PM) = 0hrs, 23 minutes (CORRECT RESULT) The formula is NOT working when: The time calculated is less than an hour across DIFFERENT hours (i.e. 2:50PM - 3:05PM) = 1hrs, 15 minutes (INCORRECT RESULT) The hour should be '0' as the total time worked is '15' minutes only. I'm not sure if I can build a condition into the already existing formula(s) or if a new formula(s) is required. The standard datediff function also produces the same result. I've tried other code located online but have not been successful at removing the hour that appears in error. I've searched the CASPIO forum but was not able to locate a like issue. Any help or suggestions would be much appreciated. Thank you!
  • Create New...