Jump to content

Search the Community

Showing results for tags 'syntax'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Caspio Bridge
    • Caspio Apps for Ukraine
    • 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

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


MSN


Website URL


ICQ


Yahoo


Skype


Location


Interests

Found 3 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. Does anyone know how to use 'contains' in a calculated field to see if the field contains a certain value, instead of using = to equal it. I have a tale with records that have a field with values like 524_789B, 524_788B, 524_794B, 524_791B, 524_1047B. And an authenticated field value might be 524_794B. I want to count the number of records that contain 524_794B. So in a calculated field I need something like below: SELECT COUNT (ItemID) FROM _V_Items Where Assigned_To CONTAINS '[@authfield:Users_CID_StaffID]' What is the syntax for 'contains'?
  3. Hi there, In the App I am currently developing I have a "View Inventory" DataPage where my users can see (for a chosen product) what the starting inventory was A, how many units are reserved / shipped B and finally how many units are available C. C is a calculated field where C = A - B On this page I also have an HTML block with a control button that my users can click to create a shipment request, but I want this to be disabled when C = 0 because as it stands right now, there is nothing stopping them from ordering an item that is out of stock. The current code for my button is as follows: '<div style="margin: 10px;"><a href="http://eu1.caspio.com/dp.asp?AppKey=cde830001d57b1a237854adab459&Stock_ID=[@field:Stock_ID]&Product_Description=[@field:Product_Description]" style="background: rgb(61, 130, 171); padding: 7px 20px; border: 1px solid rgb(221, 221, 221); border-image: none; color: rgb(255, 255, 255); font-weight: bold; text-decoration: none; white-space: nowrap;">Create Shipment Request</a></div>' I read on another post on here that the way to address this was to use Javascript, so following that advice I changed the code for my button the the following: <script type="text/javascript"> var cb_boolean = '[@calcfield:1]'; if (cb_boolean != '0') { document.write("<input type='button' value='Create Shipment Request' Name='mybutton' onclick='myfunction()'> "); } else { document.write("<input type='button' value='Out Of Stock!' Name='mybutton' disabled=true>"); } function myfunction() { window.location.href='http://eu1.caspio.com/dp.asp?AppKey=cde830001d57b1a237854adab459&Stock_ID=[@field:Stock_ID]&Product_Description=[@field:Product_Description]'; } </script> This worked in terms of disabling my button where C = 0, but then the parameters were no longer being passed to my shipment request DataPage. I suspect this is a syntax error of some sort, but being a newbie to the worlds of both HTML and Javascript I just don't know what I need to change. Any advice would be much appreciated Thanks
×
×
  • Create New...