快速计数查询

你好,

希望有人能让我的生活更轻松。

我目前使用以下计数公式:

=COUNTIFS({CoCode}, "114",{状态。},“未启动”)

我可以将其更改为什么,以便我不必每次都手动输入新的公司代码(例如114)和状态(例如未启动)?想象一下,我可以通过某种方式告诉公式将文本包含在某个单元格中,然后将其向下/横向拖动等。

这是它目前的样子供参考。

image.png


谢谢你!

标签:

最佳答案

  • 保罗新来的
    保罗新来的 ✭✭✭✭✭✭
    ✓回答

    你可以这样说:

    =COUNTIFS({CoCode}, $[Column7]@row, {Status。}, Column8 15美元)


    只需将[Column8]$后的15更改为包含该文本的任何行号。然后你可以向下和向右拖动填充。

    thinkspi.com

答案

帮助文章参考资料欧宝体育app官方888

想要直接在智能表中练习使用公式吗?

请查看公式手册模板!
Instead of comparing to the count of children, you would compare to the count of children that are blank or not blank.<\/p>


<\/p>

Change<\/p>

COUNT(CHILDREN())<\/p>

to<\/p>

COUNTIFS(CHILDREN(), OR(@cell <> \"//www.santa-greenland.com/community/discussion/106203/\", @cell = \"//www.santa-greenland.com/community/discussion/106203/\"))<\/p>"}]}},"status":{"statusID":3,"name":"Accepted","state":"closed","recordType":"discussion","recordSubType":"question"},"bookmarked":false,"unread":false,"category":{"categoryID":322,"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions","allowedDiscussionTypes":[]},"reactions":[{"tagID":3,"urlcode":"Promote","name":"Promote","class":"Positive","hasReacted":false,"reactionValue":5,"count":0},{"tagID":5,"urlcode":"Insightful","name":"Insightful","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":11,"urlcode":"Up","name":"Vote Up","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":13,"urlcode":"Awesome","name":"Awesome","class":"Positive","hasReacted":false,"reactionValue":1,"count":0}],"tags":[{"tagID":254,"urlcode":"Formulas","name":"Formulas"}]},{"discussionID":106335,"type":"question","name":"Match Learner by Location in a Training Tracker for Metric Sheet","excerpt":"I am missing something, but I think it is because I am not accustom to working with dates. I am creating a metric sheet for dashboard. I have a training tracker that populates a date by a learners name & demographics (row) with columns of different courses (date columns). I didn't think the formula would be difficult , but…","categoryID":322,"dateInserted":"2023-06-12T19:39:08+00:00","dateUpdated":null,"dateLastComment":"2023-06-12T20:03:20+00:00","insertUserID":150616,"insertUser":{"userID":150616,"name":"benlight","url":"https:\/\/community.smartsheet.com\/profile\/benlight","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-06-12T20:23:28+00:00","banned":0,"punished":0,"private":false,"label":"✭✭"},"updateUserID":null,"lastUserID":150616,"lastUser":{"userID":150616,"name":"benlight","url":"https:\/\/community.smartsheet.com\/profile\/benlight","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-06-12T20:23:28+00:00","banned":0,"punished":0,"private":false,"label":"✭✭"},"pinned":false,"pinLocation":null,"closed":false,"sink":false,"countComments":2,"countViews":30,"score":null,"hot":3373200148,"url":"https:\/\/community.smartsheet.com\/discussion\/106335\/match-learner-by-location-in-a-training-tracker-for-metric-sheet","canonicalUrl":"https:\/\/community.smartsheet.com\/discussion\/106335\/match-learner-by-location-in-a-training-tracker-for-metric-sheet","format":"Rich","lastPost":{"discussionID":106335,"commentID":380182,"name":"Re: Match Learner by Location in a Training Tracker for Metric Sheet","url":"https:\/\/community.smartsheet.com\/discussion\/comment\/380182#Comment_380182","dateInserted":"2023-06-12T20:03:20+00:00","insertUserID":150616,"insertUser":{"userID":150616,"name":"benlight","url":"https:\/\/community.smartsheet.com\/profile\/benlight","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-06-12T20:23:28+00:00","banned":0,"punished":0,"private":false,"label":"✭✭"}},"breadcrumbs":[{"name":"Home","url":"https:\/\/community.smartsheet.com\/"},{"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions"}],"groupID":null,"statusID":3,"attributes":{"question":{"status":"accepted","dateAccepted":"2023-06-12T20:23:36+00:00","dateAnswered":"2023-06-12T19:52:03+00:00","acceptedAnswers":[{"commentID":380176,"body":"

=COUNTIFS({Learner Location Range}, [Location]@row, {Course Completion Date}, ISDATE(@cell))<\/p>

If I understand your scenario correctly, this may work.<\/p>"},{"commentID":380182,"body":"

Awesome, <\/p>

Exactly it! I was not identifying the date@cell. <\/p>

Thank you so very much!<\/p>"}]}},"status":{"statusID":3,"name":"Accepted","state":"closed","recordType":"discussion","recordSubType":"question"},"bookmarked":false,"unread":false,"category":{"categoryID":322,"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions","allowedDiscussionTypes":[]},"reactions":[{"tagID":3,"urlcode":"Promote","name":"Promote","class":"Positive","hasReacted":false,"reactionValue":5,"count":0},{"tagID":5,"urlcode":"Insightful","name":"Insightful","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":11,"urlcode":"Up","name":"Vote Up","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":13,"urlcode":"Awesome","name":"Awesome","class":"Positive","hasReacted":false,"reactionValue":1,"count":0}],"tags":[]},{"discussionID":106316,"type":"question","name":"Please assist with this formula. Thanks.","excerpt":"All data is in a single sheet. I need all rows in a column titled \"Status\" to be populated with \"APPROVED\" when the following conditions are met: \"Yes\" in column titled \"BU Approval\", \"Green\" or \"Yellow\" in column titled \"B\", \"Accepted\" or \"N\/A\" in column titled \"C\", date in column titled \"D\" is today or in future, Box in…","categoryID":322,"dateInserted":"2023-06-12T13:36:54+00:00","dateUpdated":"2023-06-12T13:37:48+00:00","dateLastComment":"2023-06-12T21:30:30+00:00","insertUserID":162293,"insertUser":{"userID":162293,"name":"AnnS","title":"Supply Chain, Strategic Category Manager","url":"https:\/\/community.smartsheet.com\/profile\/AnnS","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-06-12T21:29:39+00:00","banned":0,"punished":0,"private":false,"label":"✭"},"updateUserID":162293,"lastUserID":162293,"lastUser":{"userID":162293,"name":"AnnS","title":"Supply Chain, Strategic Category Manager","url":"https:\/\/community.smartsheet.com\/profile\/AnnS","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-06-12T21:29:39+00:00","banned":0,"punished":0,"private":false,"label":"✭"},"pinned":false,"pinLocation":null,"closed":false,"sink":false,"countComments":5,"countViews":44,"score":null,"hot":3373185444,"url":"https:\/\/community.smartsheet.com\/discussion\/106316\/please-assist-with-this-formula-thanks","canonicalUrl":"https:\/\/community.smartsheet.com\/discussion\/106316\/please-assist-with-this-formula-thanks","format":"Rich","lastPost":{"discussionID":106316,"commentID":380215,"name":"Re: Please assist with this formula. Thanks.","url":"https:\/\/community.smartsheet.com\/discussion\/comment\/380215#Comment_380215","dateInserted":"2023-06-12T21:30:30+00:00","insertUserID":162293,"insertUser":{"userID":162293,"name":"AnnS","title":"Supply Chain, Strategic Category Manager","url":"https:\/\/community.smartsheet.com\/profile\/AnnS","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-06-12T21:29:39+00:00","banned":0,"punished":0,"private":false,"label":"✭"}},"breadcrumbs":[{"name":"Home","url":"https:\/\/community.smartsheet.com\/"},{"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions"}],"groupID":null,"statusID":3,"attributes":{"question":{"status":"accepted","dateAccepted":"2023-06-12T21:29:38+00:00","dateAnswered":"2023-06-12T14:12:27+00:00","acceptedAnswers":[{"commentID":380089,"body":"

Hi @AnnS<\/a>,<\/p>

You need some OR statements in there for the multiple options:<\/p>

=IF(AND([BU Approval]@row = \"Yes\", OR(B@row = \"Green\", B@row = \"Yellow\"), OR(C@row = \"Accepted\", C@row = \"N\/A\"), D@row >= TODAY(), E@row = 1), \"APPROVED\", \"//www.santa-greenland.com/community/discussion/106203/\")<\/p>

Example output:<\/p>

\n
\n \n \"image.png\"<\/img><\/a>\n <\/div>\n<\/div>\n

Hope this helps - if there any issues just post and we can work them out!<\/p>"}]}},"status":{"statusID":3,"name":"Accepted","state":"closed","recordType":"discussion","recordSubType":"question"},"bookmarked":false,"unread":false,"category":{"categoryID":322,"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions","allowedDiscussionTypes":[]},"reactions":[{"tagID":3,"urlcode":"Promote","name":"Promote","class":"Positive","hasReacted":false,"reactionValue":5,"count":0},{"tagID":5,"urlcode":"Insightful","name":"Insightful","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":11,"urlcode":"Up","name":"Vote Up","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":13,"urlcode":"Awesome","name":"Awesome","class":"Positive","hasReacted":false,"reactionValue":1,"count":0}],"tags":[]}],"initialPaging":{"nextURL":"https:\/\/community.smartsheet.com\/api\/v2\/discussions?page=2&categoryID=322&includeChildCategories=1&type%5B0%5D=Question&excludeHiddenCategories=1&sort=-hot&limit=3&expand%5B0%5D=all&expand%5B1%5D=-body&expand%5B2%5D=insertUser&expand%5B3%5D=lastUser&status=accepted","prevURL":null,"currentPage":1,"total":9972,"limit":3},"title":"Trending in Formulas and Functions ","subtitle":null,"description":null,"noCheckboxes":true,"containerOptions":[],"discussionOptions":[]}">

公式和函数趋势