INFORMATION_SCHEMA.RECOMMENDATIONS_BY_ORGANIZATION view

Preview

This product or feature is subject to the "Pre-GA Offerings Terms" in the General Service Terms section of theService Specific Terms. Pre-GA products and features are available "as is" and might have limited support. For more information, see thelaunch stage descriptions.

To request feedback or support for this feature, send email tobq-recommendations+feedback@google.com.

TheINFORMATION_SCHEMA.RECOMMENDATIONS_BY_ORGANIZATION view contains data about all BigQueryrecommendations for all projects in the current organization.

TheINFORMATION_SCHEMA.RECOMMENDATIONS_BY_ORGANIZATION view supports the followingrecommendations:

This schema view is only available to users with definedGoogle Cloud organizations.

Required permissions

To view recommendations with theINFORMATION_SCHEMA.RECOMMENDATIONS_BY_ORGANIZATION view, you must have therequired permissions for the corresponding recommender. TheINFORMATION_SCHEMA.RECOMMENDATIONS_BY_ORGANIZATION view only returnsrecommendations that you have permission to view. When you have the requiredpermissions on the organization, you can view recommendations for all projectswithin that organization, regardless of your permissions on the project itself.

Ask your administrator to grant access to view the recommendations. To see therequired permissions for each recommender, see the following:

Schema

TheINFORMATION_SCHEMA.RECOMMENDATIONS_BY_ORGANIZATION view has the followingschema:

Column nameData typeValue
recommendation_idSTRINGBase64 encoded ID that contains the RecommendationID and recommender.
recommenderSTRINGThe type of recommendation. For example,google.bigquery.table.PartitionClusterRecommender for partitioning and clustering recommendations.
subtypeSTRINGThe subtype of the recommendation.
project_idSTRINGThe ID of the project.
project_numberSTRINGThe number of the project.
descriptionSTRINGThe description about the recommendation.
last_updated_timeTIMESTAMPThis field represents the time when the recommendation was last created.
target_resourcesSTRINGFully qualified resource names this recommendation is targeting.
stateSTRINGThe state of the recommendation. For a list of possible values, seeState.
primary_impactRECORDThe impact this recommendation can have when trying to optimize the primary category. Contains the following fields:
  • category: The category this recommendation is trying to optimize. For a list of possible values, seeCategory.
  • cost_projection: This value may be populated if the recommendation can project the cost savings from this recommendation. Only present when the category isCOST.
  • security_projection: Might be present when the category isSECURITY.
prioritySTRINGThe priority of the recommendation. For a list of possible values, seePriority.
associated_insight_idsSTRINGFull Insight names associated with the recommendation.Insight name is the Base64 encoded representation of Insight type name & the Insight ID. This can be used to query Insights view.
additional_detailsRECORDAdditional Details about the recommendation.
  • overview: Overview of the recommendation in JSON format. The content of this field might change based on the recommender.
  • state_metadata: Metadata about the state of the recommendation in key-value pairs.
  • operations: List of operations the user can perform on the target resources. This contains the following fields:
    • action: The type of action the user must perform. This can be a free-text set by the system while generating the recommendation. Will always be populated.
    • resource_type: The cloud resource type.
    • resource: Fully qualified resource name.
    • path: Path of the target field relative to the resource.
    • value: Value of the path field.

For stability, we recommend that you explicitly list columns in your information schema queries instead ofusing a wildcard (SELECT *). Explicitly listing columns prevents queries frombreaking if the underlying schema changes.

Scope and syntax

Queries against this view must include aregion qualifier. A project IDis optional. If no project ID is specified, the project that the query runsin is used.

View nameResource scopeRegion scope
[PROJECT_ID.]`region-REGION`.INFORMATION_SCHEMA.RECOMMENDATIONS[_BY_ORGANIZATION]Project levelREGION
Replace the following:
  • Optional:PROJECT_ID: the ID of your Google Cloud project. If not specified, the default project is used.
  • REGION: anydataset region name. For example,`region-us`.

    Note: You must usea region qualifier to queryINFORMATION_SCHEMA views. The location of the query execution must match the region of theINFORMATION_SCHEMA view.

Example

To run the query against a project other than your default project, add theproject ID in the following format:

`PROJECT_ID`.`region-REGION_NAME`.INFORMATION_SCHEMA.RECOMMENDATIONS_BY_ORGANIZATION
Replace the following:

  • PROJECT_ID: the ID of the project.
  • REGION_NAME: the region for your project.

For example,`myproject`.`region-us`.INFORMATION_SCHEMA.RECOMMENDATIONS_BY_ORGANIZATION.

View materialized view recommendations in organization

The following example returns materialized view recommendations in theorganization:

SELECTproject_id,LAX_INT64(additional_details.overview.bytesSavedMonthly)/POW(1024,3)asest_gb_saved_monthly,LAX_INT64(additional_details.overview.slotMsSavedMonthly)/(1000*3600)asslot_hours_saved_monthly,last_updated_timeFROM`region-us`.INFORMATION_SCHEMA.RECOMMENDATIONS_BY_ORGANIZATIONWHERErecommender='google.bigquery.materializedview.Recommender'LIMIT3;
Note:INFORMATION_SCHEMA view names are case sensitive.

The result is similar to the following:

+-------------------------------+----------------------------------------------------------------------+|          project_id           | est_gb_saved_monthly| slot_hours_saved_monthly |  last_updated_time  |+-------------------------------+----------------------------------------------------------------------+| project1                      |   4689.071544663957 |       2682.1816833333337 | 2024-07-01 13:00:31 || project2                      |   137.5052567309467 |        9613.139166666666 | 2024-07-01 13:00:31 || project3                      |  146.83722260318973 |        7093.014316666667 | 2024-07-01 13:00:31 |+-------------------------------+----------------------------------------------------------------------+

Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2026-02-19 UTC.