{"id":2988,"date":"2017-03-17T11:34:28","date_gmt":"2017-03-17T14:34:28","guid":{"rendered":"https:\/\/www.sheetgo.com\/?p=2988"},"modified":"2017-03-17T11:34:28","modified_gmt":"2017-03-17T14:34:28","slug":"e-formula-do-google-sheets","status":"publish","type":"post","link":"https:\/\/www.sheetgo.com\/pt\/blog\/google-sheets-formulas\/and-formula-google-sheets\/","title":{"rendered":"Como usar a fun\u00e7\u00e3o AND do Planilhas Google"},"content":{"rendered":"<p>[et_pb_section fb_built=&#8221;1&#8243; admin_label=&#8221;section&#8221; module_class=&#8221;sheetgo-post&#8221; _builder_version=&#8221;4.16&#8243; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;][et_pb_row _builder_version=&#8221;4.24.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;][et_pb_column type=&#8221;4_4&#8243; _builder_version=&#8221;4.24.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;][et_pb_text _builder_version=&#8221;4.24.1&#8243; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<p><span style=\"font-weight: 400;\">The AND function in Google Sheets accepts logical expressions as input arguments, then evaluates them as <\/span><a href=\"https:\/\/www.sheetgo.com\/blog\/google-sheets-formulas\/true-formula-google-sheets\/\"><span style=\"font-weight: 400;\">TRUE<\/span><\/a><span style=\"font-weight: 400;\"> or <\/span><a href=\"https:\/\/www.sheetgo.com\/blog\/google-sheets-formulas\/false-formula-google-sheets\/\"><span style=\"font-weight: 400;\">FALSE<\/span><\/a><span style=\"font-weight: 400;\">.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">If all of the input arguments evaluate to TRUE, then the formula returns TRUE as the end result. However, if any of the input arguments evaluate to FALSE, the formula returns FALSE as an output.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">In other words, all logical expressions need to be true for AND to return TRUE.<\/span><\/p>\n<p>[\/et_pb_text][\/et_pb_column][\/et_pb_row][et_pb_row admin_label=&#8221;row&#8221; _builder_version=&#8221;4.16&#8243; background_size=&#8221;initial&#8221; background_position=&#8221;top_left&#8221; background_repeat=&#8221;repeat&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;][et_pb_column type=&#8221;4_4&#8243; _builder_version=&#8221;4.16&#8243; custom_padding=&#8221;|||&#8221; global_colors_info=&#8221;{}&#8221; custom_padding__hover=&#8221;|||&#8221; theme_builder_area=&#8221;post_content&#8221;][et_pb_text _builder_version=&#8221;4.24.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<h2><span style=\"font-weight: 400;\">AND function Syntax<\/span><\/h2>\n<p>[\/et_pb_text][et_pb_text module_class=&#8221;spreadsheet-function&#8221; _builder_version=&#8221;4.24.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<p><span style=\"font-weight: 400;\">=AND(logical_expression1, [logical_expression2, \u2026])<\/span><\/p>\n<p>[\/et_pb_text][et_pb_text _builder_version=&#8221;4.24.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><b>logical_expression1<\/b><span style=\"font-weight: 400;\"> \u2013 an expression that evaluates as TRUE or FALSE. IT can also be a reference to the cell that contains a logical expression.<\/span><\/li>\n<li><b>[logical_expression2, \u2026]<\/b><span style=\"font-weight: 400;\"> \u2013 these are optional expressions for the function to evaluate.<\/span><\/li>\n<\/ul>\n<p>[\/et_pb_text][et_pb_text _builder_version=&#8221;4.24.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<h2><span style=\"font-weight: 400;\">How to use the AND function<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">Let\u2019s try various combinations of input arguments within the AND formula and examine the results.<\/span><\/p>\n<p>[\/et_pb_text][et_pb_image src=&#8221;https:\/\/static.sheetgo.com\/wp-content\/uploads\/2021\/11\/google-sheets-AND-formula-1.png&#8221; alt=&#8221;google sheets AND formula 1&#8243; title_text=&#8221;google sheets AND formula 1&#8243; _builder_version=&#8221;4.16&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;][\/et_pb_image][et_pb_text _builder_version=&#8221;4.24.1&#8243; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<p><span style=\"font-weight: 400;\">You may have already guessed that the first two examples, each with a single expression, aren\u2019t that useful to us.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">It is interesting to note that the AND function works even with numbers as input. In this case, it simply evaluates them as FALSE if they are zero or TRUE for any other value. Check out the examples below.<\/span><\/p>\n<p>[\/et_pb_text][et_pb_image src=&#8221;https:\/\/static.sheetgo.com\/wp-content\/uploads\/2021\/11\/google-sheets-AND-formula-2.png&#8221; alt=&#8221;google sheets AND formula 2&#8243; title_text=&#8221;google sheets AND formula 2&#8243; _builder_version=&#8221;4.16&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;][\/et_pb_image][et_pb_text _builder_version=&#8221;4.24.1&#8243; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<p><span style=\"font-weight: 400;\">The AND function also takes a range of cells as an input, as shown below.<\/span><\/p>\n<p>[\/et_pb_text][et_pb_image src=&#8221;https:\/\/static.sheetgo.com\/wp-content\/uploads\/2021\/11\/google-sheets-AND-formula-3.png&#8221; alt=&#8221;google sheets AND formula 3&#8243; title_text=&#8221;google sheets AND formula 3&#8243; _builder_version=&#8221;4.16&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;][\/et_pb_image][et_pb_text _builder_version=&#8221;4.24.1&#8243; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<p><span style=\"font-weight: 400;\">While it is hard to deny the utility of the AND formula in the real world, it has limited applications as a standalone function.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">However, when used in conjunction with other formulas like <\/span><a href=\"https:\/\/www.sheetgo.com\/blog\/google-sheets-formulas\/if-formula-google-sheets\/\"><span style=\"font-weight: 400;\">IF<\/span><\/a><span style=\"font-weight: 400;\">, we can see its magic coming to life. In the examples below, look at the first and third formulas. <\/span><span style=\"font-weight: 400;\">The second and fourth formulas are their alternatives. Notice how simple it gets when we use AND instead of multi-level IF formula nesting.<\/span><\/p>\n<p>[\/et_pb_text][et_pb_image src=&#8221;https:\/\/static.sheetgo.com\/wp-content\/uploads\/2021\/11\/google-sheets-AND-formula-4.png&#8221; alt=&#8221;google sheets AND formula 4&#8243; title_text=&#8221;google sheets AND formula 4&#8243; _builder_version=&#8221;4.16&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;][\/et_pb_image][et_pb_text _builder_version=&#8221;4.24.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<h2><span style=\"font-weight: 400;\">Combining AND and FILTER functions<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">You can combine FILTER and AND to extract data if it meets multiple conditions.<\/span><\/p>\n<p>[\/et_pb_text][et_pb_text module_class=&#8221;spreadsheet-function&#8221; _builder_version=&#8221;4.24.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<p><span style=\"font-weight: 400;\">=FILTER(A:C, AND(A:A &gt; 50, B:B &lt;100))<\/span><\/p>\n<p>[\/et_pb_text][et_pb_text _builder_version=&#8221;4.24.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<p><span style=\"font-weight: 400;\">This formula filters the range A1:C10 to include only the rows where the values in column A are greater than 50 and the values in column B are less than 100.<\/span><\/p>\n<p>[\/et_pb_text][et_pb_text _builder_version=&#8221;4.24.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<h2><span style=\"font-weight: 400;\">AND function with conditional formatting<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">Usually you can only set one condition to apply a certain formatting. But with AND you can apply multiple criteria.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Just follow these simple steps:<\/span><\/p>\n<ol>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Select the range you want to format.<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Go to <\/span><b>Format<\/b><span style=\"font-weight: 400;\"> &gt; <\/span><b>Conditional formatting<\/b><span style=\"font-weight: 400;\">.<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">In the <\/span><b>Custom formula is<\/b><span style=\"font-weight: 400;\"> field.<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Insert the ANDfunction so the condition includes two values.<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Choose the formatting style and click Done.<\/span><\/li>\n<\/ol>\n<p>[\/et_pb_text][et_pb_text _builder_version=&#8221;4.24.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221; theme_builder_area=&#8221;post_content&#8221;]<\/p>\n<h3>AND function<\/h3>\n<p><span style=\"font-weight: 400;\">The AND function in Google Sheets is a versatile tool for evaluating multiple conditions in your data analysis.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">By combining it with other features you can create powerful and complex formulas to meet your specific needs.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">If you want a function that evaluates to TRUE if any of the conditions are met, then you need to <\/span><a href=\"https:\/\/www.sheetgo.com\/blog\/google-sheets-formulas\/or-formula-google-sheets\/\"><span style=\"font-weight: 400;\">learn about the OR function<\/span><\/a><span style=\"font-weight: 400;\">.<\/span><\/p>\n<p>[\/et_pb_text][\/et_pb_column][\/et_pb_row][\/et_pb_section]<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The AND function in Google Sheets accepts logical expressions as input arguments, then evaluates them as TRUE or FALSE. If all of the input arguments evaluate to TRUE, then the formula returns TRUE as the end result. However, if any of the input arguments evaluate to FALSE, the formula returns FALSE as an output. In [&hellip;]<\/p>\n","protected":false},"author":40,"featured_media":254715,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"_et_pb_use_builder":"on","_et_pb_old_content":"The utility of the entire range of formulas in Google Sheets won't be complete without the <a href=\"https:\/\/support.google.com\/docs\/answer\/3093301?hl=en\">AND<\/a> formula. It accepts logical expressions as input arguments, evaluates them to either a logical TRUE or FALSE. If all of the input arguments evaluate to TRUE, then the formula returns TRUE as the end result. However, if any of the input arguments evaluate to FALSE, the formula returns FALSE as an output.\n<h3>Syntax<\/h3>\n<span style=\"font-family: courier new,courier,monospace; font-size: 14pt;\"><strong>AND(logical_expression1, [logical_expression2, ...])<\/strong><\/span>\n\n<span style=\"font-family: courier new,courier,monospace; font-size: 12pt;\"><strong>logical_expression1<\/strong><\/span> - is an expression that evaluates to a logical TRUE or FALSE. This can be a direct expression or a reference to the cell that represents a logical expression.\n\n<span style=\"font-family: courier new,courier,monospace; font-size: 12pt;\"><strong>[logical_expression2, ...]<\/strong><\/span> - these are optional and additional expressions that return a logical TRUE or FALSE.\n<h3>Usage: AND Formula<\/h3>\nLet us try various combinations of input arguments within the AND formula and examine the results. You may have already guessed that the first two variations of the formula with single input argument, aren't that useful to us.\n\n<img class=\"aligncenter size-full wp-image-2990\" src=\"https:\/\/static.sheetgo.com\/wp-content\/uploads\/2017\/11\/and1.png\" alt=\"AND Formula - Illustration 1\" width=\"378\" height=\"221\" \/>\n\nIt is interesting to note that the AND formula works even when we provide numbers as the input arguments. What happens when the Google Sheets application encounters a number when it is expecting a logical TRUE or FALSE? It simply converts them to a logical TRUE or FALSE. A zero is converted to FALSE and a non-zero to TRUE. Doesn't really matter if the numbers contain decimals. Please see the examples in the snapshot below.\n\n<img class=\"aligncenter size-full wp-image-2991\" src=\"https:\/\/static.sheetgo.com\/wp-content\/uploads\/2017\/11\/and2.png\" alt=\"AND Formula - Illustration 2\" width=\"322\" height=\"173\" \/>\n\nThe AND formula also takes a range of cells as an input argument, as illustrated in the image below.\n\n<img class=\"aligncenter size-full wp-image-2993\" src=\"https:\/\/static.sheetgo.com\/wp-content\/uploads\/2017\/11\/and3.png\" alt=\"AND Formula - Illustration 4\" width=\"368\" height=\"177\" \/>\n\nWhile it is hard to deny the utility of the AND formula in the real world, probably it has a limited application as a standalone formula. However, when it is used in conjunction with other formulas like IF, we can see its magic coming to life. In the snapshot below, consider the first and third formulas. The second and fourth formulas are their alternatives. Notice how simple it gets when we use AND instead of multi-level IF formula nesting.\n\n<img class=\"aligncenter size-full wp-image-2992\" src=\"https:\/\/static.sheetgo.com\/wp-content\/uploads\/2017\/11\/and4.png\" alt=\"AND Formula - Illustration 3\" width=\"613\" height=\"172\" \/>\n\n\u00a0\n\n\u00a0","_et_gb_content_width":"","footnotes":""},"categories":[54],"tags":[39,28],"class_list":["post-2988","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-google-sheets-formulas","tag-connections-t","tag-spreadsheets"],"acf":[],"_links":{"self":[{"href":"https:\/\/www.sheetgo.com\/pt\/wp-json\/wp\/v2\/posts\/2988","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.sheetgo.com\/pt\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.sheetgo.com\/pt\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.sheetgo.com\/pt\/wp-json\/wp\/v2\/users\/40"}],"replies":[{"embeddable":true,"href":"https:\/\/www.sheetgo.com\/pt\/wp-json\/wp\/v2\/comments?post=2988"}],"version-history":[{"count":0,"href":"https:\/\/www.sheetgo.com\/pt\/wp-json\/wp\/v2\/posts\/2988\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.sheetgo.com\/pt\/wp-json\/wp\/v2\/media\/254715"}],"wp:attachment":[{"href":"https:\/\/www.sheetgo.com\/pt\/wp-json\/wp\/v2\/media?parent=2988"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.sheetgo.com\/pt\/wp-json\/wp\/v2\/categories?post=2988"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.sheetgo.com\/pt\/wp-json\/wp\/v2\/tags?post=2988"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}