Jump to content

eetimm

Members
  • Content Count

    17
  • Joined

  • Last visited

  • Days Won

    2

eetimm last won the day on June 6 2019

eetimm had the most liked content!

About eetimm

  • Rank
    Member

Recent Profile Visitors

407 profile views
  1. I will test that out. That might work for me. Thanks for the suggestion!
  2. Thanks for the help. The data in the search_alpha field is text, and I am using a multi-select listbox to create the field, and then using JS to format the field as "8426 OR 7506...". I use this field to create a subset of my overall database by passing the string as a parameter and using "contains" to limit the data. In this particular case, I am hoping to do some calculations (Min, Max, Avg) on the subset. My approach was to see if I could pass the string to the WHERE clause of a SQL Select statement so I can make the calculation only on the values in the subset. Not sure if this is the correct approach. The overall project is an online analysis tool that allows users to select a subset of industry firms and then view some basic metrics. There will be multiple users running the tool at the same time, and each one will be able to save their own subset of the industry for analysis. I appreciate any help!
  3. I am going to document my efforts here just in case anyone else is looking for a similar answer... When I use the "target.[@field:search_alpha] with a single entry in the field (using '8426' rather than the string "'8426' or cert='7506'"), I do get the correct response. So, it appears the issue is calculating the max value from the multiple records I am submitting. It appears that the SQL needs a match of a single data point in the WHERE clause. Any other methods to grab the max value out of a range of values in a calculated field, using another field as the criteria?
  4. I found some info on the use of "target." here https://howto.caspio.com/datapages/reports/advanced-reporting/calculations-in-forms-and-reports/. This looks like it is getting closer. I will keep messing with it. Thanks!
  5. Thanks for your response! I appreciate the help. Unfortunately, it did not work. I was not aware of the "target." designation. Can you give me a brief explanation of how that works?
  6. Thanks for your response! I appreciate the help. Unfortunately, it did not work. I was not aware of the "target." designation. Can you give me a brief explanation of how that works?
  7. I am trying to use a SQL query in a calculated field to calculate the max value in a sub-group of data. When I hard code the formula as below, it works fine. SELECT Max(CY_Inc) FROM Pohl_Data_Temp WHERE cert = '8426' OR cert='7506' OR cert='660' OR cert='11681' OR cert='29679' OR cert='9507' What I am trying to do is fill in my where statement dynamically from a field in my database. When I use the following formula, it returns a blank result. SELECT Max(CY_Inc) FROM Pohl_Data_Temp WHERE cert = [@field:search_alpha] Field [search_alpha] = '8426' OR cert='7506' OR cert='660' OR cert='11681' OR cert='29679' OR cert='9507' Field [cert] is a unique ID field Since the hard coded formula works, I believe that I have the syntax correct, leading me to conclude that a SQL Select in a calculated field cannot use a field to provide the conditions for the where statement. I have not used a lot of SQL in calculated fields, so it is possible that I am missing something here. I appreciate any thoughts and insights!
  8. Check your fields for null values...Caspio cannot add values if any of them are null. Try using the form: IsNull([@field:field1],0)+ IsNull([@field:field2],0) + .... + IsNull([@field:fieldx],0) This has worked for me. ET
  9. Aurora...thanks so much for this, it works perfectly. I really appreciate your taking the time to figure this out! Regards, ET
  10. Thanks again for your help. Unfortunately, that did not do the trick. I am suspecting that the problem lies with the use of virtual fields, so I will try this in plain HTML. ET
  11. I will give that a try. Thanks for the answer and I will let you know the results. ET
  12. I have a subscription form that is using a virtual radio button field (field: Virutal7) to force subscribers into choosing one of two versions. If the user clicks on the second option (Community Bank Version) I would like to update a hidden checkbox field (field: CBVer) with a check to track the version in our database. I am using the radio button so I can make the choice of a version a required field. I wrote the following JS to attempt to switch the checkbox when the user selects the second option, but to no avail. If anyone could take a look at this I would greatly appreciate it. Sample page: http://b2.caspio.com/dp.asp?AppKey=73be1000803de3ead2044f3ebe07 <SCRIPT LANGUAGE="JavaScript"> function addcbver() { if (document.getElementById('cbParamVirtual71').checked==true) { document.getElementById('InsertRecordCBVer').checked = true; } } document.getElementByID('cbParamVirtual7').onchange=addcbver; </SCRIPT> Regards, ET
  13. I have a details datapage with a dropdown to select a single customer, and also have a multi-select listbox to choose a range of similar customers for comparison (the customers are sorted in ascending order by revenue). I would like to have my listbox set the focus on the customer selected in the dropdown, so the user will not need to scroll through the entire list. I saw this JS and tried messing with it to see if it could be modified to set the focus when selecting the dropdown, but it does not work that way. Can this even be done in JS or should I just figure out another way? Thanks in advance. ET
  14. Just off the top of my head, but you might look into building the second page you mentioned, and use a calculated field to display the data. There are a few formulas available in calculated fields that will let you trim the leading and following spaces of a field. I do not know if Caspio actually pads out a 2,000 character text field with spaces, but maybe the trim function will return only the text string. Hope this helps, I have not checked any of it out myself... ET
  15. Finally got this to work... I used [@authfield:Member_ID] to get the ID of the logged-in user and that worked. It is always something....
×
×
  • Create New...