-- DBMS: bigquery
CREATE TABLE `isb-cgc-bq.HTAN_versioned.clinical_tier3_breast_r4`
(
  Breast_Cancer_Genomic_Test_Performed STRING OPTIONS(description="Text term that represents the name of the genomic test performed for breast cancer."),
  Breast_Carcinoma_ER_Staining_Intensity STRING OPTIONS(description="Text term to indicate the ER staining intensity on pathology assessment in a participant with breast cancer"),
  Breast_Carcinoma_ER_Status_Percentage_Value STRING OPTIONS(description="A numerical quantity measured or assigned or computed which captures the estrogen receptor level measured in a participant with breast cancer"),
  Id STRING OPTIONS(description="Unique identifier of entity e.g. a96059eb-81af-4b24-ae50-9242c0d8f819"),
  Breast_Carcinoma_Histology_Category STRING OPTIONS(description="Classification of the type of invasive breast carcinoma diagnosed based on histologic attributes."),
  Timepoint_Label STRING OPTIONS(description="Label to identify the time point at which the clinical data or biospecimen was obtained (e.g. Baseline, End of Treatment, Overall survival, Final). NO PHI/PII INFORMATION IS ALLOWED."),
  Multifocal_Breast_Carcinoma_Present_Indicator STRING OPTIONS(description="A response to indicate if there is breast cancer characterized by the presence of multiple cancerous tumors that originate from the same clone and usually located in the same quadrant of the breast."),
  Breast_Biopsy_Procedure_Finding_Type STRING OPTIONS(description="Text term to describe the result of the examination of the breast tissue specimen or fluid as related to the presence and nature of disease."),
  Hormone_Therapy_Breast_Cancer_Prevention_Indicator STRING OPTIONS(description="Did the patient receive hormonal therapy for prevention of breast cancer?"),
  Breast_Carcinoma_Centromere_17_Copy_Number STRING OPTIONS(description="Result of Centromere 17 testing in a sample or specimen of metastatic breast carcinoma, expressed as a range of values."),
  entityId STRING OPTIONS(description="Synapse ID of entity"),
  Breast_Carcinoma_HER2_Ratio_Diagnosis STRING OPTIONS(description="HER2 ratio of the participant at diagnosis"),
  Component STRING OPTIONS(description="Category of metadata (e.g. Diagnosis, Biospecimen, scRNA-seq Level 1, etc.); provide the same one for all items/rows."),
  Oncotype_Risk_Group STRING OPTIONS(description="Text term that represents the risk group for breast cancer as determined by assessment of the Oncotype recurrence score."),
  Breast_Carcinoma_Detection_Method_Type STRING OPTIONS(description="The means, manner of procedure, or systematic course of actions performed in order to discover or identify breast cancer."),
  Breast_Carcinoma_Progesteroner_Receptor_Status STRING OPTIONS(description="Text term to represent the overall result of Progresterone Receptor (PR) testing in a participant with breast cancer"),
  HER2_Breast_Carcinoma_Copy_Number_Total STRING OPTIONS(description="Result of HER2 Copy Number testing (in a participant with breast cancer), expressed as a range of values."),
  Breast_Carcinoma_HER2_Chromosome17_Ratio STRING OPTIONS(description="HER2 chromosome 17 ratio in participants with breast cancer"),
  Breast_Carcinoma_PR_Staining_Intensity STRING OPTIONS(description="Text term to indicate the PR staining intensity on pathology assessment in a participant with breast cancer"),
  Oncotype_Score STRING OPTIONS(description="OncotypeDX recurrence score"),
  Breast_Imaging_Performed_Type STRING OPTIONS(description="The kind of technology or method performed for screening, diagnosis, surgical procedures or therapy that aids in the visualization of the breast(s)."),
  Breast_Carcinoma_Surgical_Procedure_Name STRING OPTIONS(description="Text name of a surgical procedure performed for a person with a diagnosis of breast cancer"),
  HTAN_Participant_ID STRING OPTIONS(description="HTAN ID associated with a patient based on HTAN ID SOP (eg HTANx_yyy )"),
  Invasive_Lobular_Breast_Carcinoma_Histologic_Category STRING OPTIONS(description="The histologic subtype for an infiltrating lobular carcinoma of the breast."),
  Breast_Carcinoma_PR_Status_Percentage_Value STRING OPTIONS(description="A numerical quantity measured or assigned or computed which captures the progesterone receptor level measured in a participant with breast cancer"),
  BIRADS_Mammography_Breast_Density_Category STRING OPTIONS(description="The category that describes the relative amount of different tissues present in the breast on a mammogram based on the updated 2015 edition of the American College of Radiology's Breast Imaging Reporting and Data System (BI-RADS) reporting guidelines."),
  Mammaprint_Risk_Group STRING OPTIONS(description="Text term that represents the risk group for breast cancer as determined by assessment of the MammaPrint test."),
  Invasive_Ductal_Breast_Carcinoma_Histologic_Category STRING OPTIONS(description="The histologic subtype for the most common type of invasive breast carcinoma."),
  Breast_Cancer_Allred_Estrogen_Receptor_Score STRING OPTIONS(description="The numeric Allred score, that is cell staining percentage plus intensity, to determine estrogen receptor status."),
  Breast_Carcinoma_HER2_Status STRING OPTIONS(description="Text term to signify the result of the medical procedure that involves testing a sample of blood or tissue for HER2 in a participant with breast cancer"),
  Stop_Days_from_Index STRING OPTIONS(description="Number of days from the date of birth (index date) to the end date of the event (e.g. exposure to environmental factor, treatment start, etc.). Note: if the event occurs at a single time point, e.g. a diagnosis or a lab test, the values for this column is 'Not Applicable'"),
  Breast_Quadrant_Site STRING OPTIONS(description="The breast quadrant or structure from which the breast tissue specimen was removed for microscopic examination."),
  Breast_Carcinoma_HER2_Centromere17_Copynumber_Total STRING OPTIONS(description="Number of Cells Counted for HER2 & Centromere 17 Copy Numbers in a participant with breast cancer"),
  Breast_Cancer_Assessment_Tests STRING OPTIONS(description="Text term to identify assessment tests done in participants during diagnosis"),
  Prior_Invasive_Breast_Disease STRING OPTIONS(description="Text term to indicate prior invasive breast condition in the participant"),
  Multicentric_Breast_Carcinoma_Present_Indicator STRING OPTIONS(description="A response to indicate if there is breast cancer characterized by the presence of multiple cancerous tumors that originate from different clones and usually located in different quadrants of the breast."),
  Breast_Carcinoma_Estrogen_Receptor_Status STRING OPTIONS(description="Text term to represent the overall result of Estrogen Receptor (ER) testing in a participant with breast cancer"),
  Start_Days_from_Index STRING OPTIONS(description="Number of days from the date of birth (index date) to the date of an event (e.g. exposure to environmental factor, treatment start, etc.). If not applicable please enter 'Not Applicable'"),
  HTAN_Center STRING OPTIONS(description="Name of HTAN Center e.g. HTAN HTAPP"),
  Manifest_Id STRING OPTIONS(description="Synapse ID of manifest containing file annotation"),
  Manifest_Version INT64 OPTIONS(description="Latest version of metadata manifest")
)
OPTIONS(
  friendly_name="HTAN CLINICAL TIER 3 DATA - BREAST R4 VERSIONED",
  description="This table contains third tier disease-agnostic extensions to the GDC clinical data model. Data was extracted from HTAN Synapse projects in October 2023 and contains patient cases and their clinical information. More details: see https://data.humantumoratlas.org/standard/clinical",
  labels=[("access", "open"), ("data_type", "clinical_data"), ("program", "htan"), ("source", "htan"), ("category", "clinical_biospecimen_data"), ("status", "current")]
);

INSERT INTO `isb-cgc-bq.HTAN_versioned.clinical_tier3_breast_r4` (Breast_Cancer_Genomic_Test_Performed, Breast_Carcinoma_ER_Staining_Intensity, Breast_Carcinoma_ER_Status_Percentage_Value, Id, Breast_Carcinoma_Histology_Category, Timepoint_Label, Multifocal_Breast_Carcinoma_Present_Indicator, Breast_Biopsy_Procedure_Finding_Type, Hormone_Therapy_Breast_Cancer_Prevention_Indicator, Breast_Carcinoma_Centromere_17_Copy_Number, entityId, Breast_Carcinoma_HER2_Ratio_Diagnosis, Component, Oncotype_Risk_Group, Breast_Carcinoma_Detection_Method_Type, Breast_Carcinoma_Progesteroner_Receptor_Status, HER2_Breast_Carcinoma_Copy_Number_Total, Breast_Carcinoma_HER2_Chromosome17_Ratio, Breast_Carcinoma_PR_Staining_Intensity, Oncotype_Score, Breast_Imaging_Performed_Type, Breast_Carcinoma_Surgical_Procedure_Name, HTAN_Participant_ID, Invasive_Lobular_Breast_Carcinoma_Histologic_Category, Breast_Carcinoma_PR_Status_Percentage_Value, BIRADS_Mammography_Breast_Density_Category, Mammaprint_Risk_Group, Invasive_Ductal_Breast_Carcinoma_Histologic_Category, Breast_Cancer_Allred_Estrogen_Receptor_Score, Breast_Carcinoma_HER2_Status, Stop_Days_from_Index, Breast_Quadrant_Site, Breast_Carcinoma_HER2_Centromere17_Copynumber_Total, Breast_Cancer_Assessment_Tests, Prior_Invasive_Breast_Disease, Multicentric_Breast_Carcinoma_Present_Indicator, Breast_Carcinoma_Estrogen_Receptor_Status, Start_Days_from_Index, HTAN_Center, Manifest_Id, Manifest_Version) VALUES (NULL, 'unknown', '0.0', 'a2760d47-a02f-49b0-b270-ca3182e38ba6', NULL, 'Biopsy 1', NULL, NULL, NULL, NULL, NULL, NULL, 'BreastCancerTier3', NULL, NULL, 'Negative', NULL, NULL, NULL, NULL, NULL, NULL, 'HTA9_7', NULL, '0.0', NULL, NULL, NULL, NULL, 'Negative', NULL, NULL, NULL, NULL, NULL, NULL, 'Negative', '24705', 'HTAN OHSU', 'syn39142015', 5), (NULL, 'unknown', '0.0', 'bd30cb1e-fec3-400b-9fe8-596c45291a0b', NULL, 'Biopsy 2', NULL, NULL, NULL, NULL, NULL, NULL, 'BreastCancerTier3', NULL, NULL, 'Negative', NULL, NULL, NULL, NULL, NULL, NULL, 'HTA9_7', NULL, '0.0', NULL, NULL, NULL, NULL, 'Negative', NULL, NULL, NULL, NULL, NULL, NULL, 'Negative', '24748', 'HTAN OHSU', 'syn39142015', 5), (NULL, 'unknown', '0.0', 'b7918414-dc6e-4785-b72c-09d0a67673c1', NULL, 'Biopsy 1', NULL, NULL, NULL, NULL, NULL, NULL, 'BreastCancerTier3', NULL, NULL, 'Negative', NULL, NULL, NULL, NULL, NULL, NULL, 'HTA9_9', NULL, '0.0', NULL, NULL, NULL, NULL, 'Negative', NULL, NULL, NULL, NULL, NULL, NULL, 'Negative', '19744', 'HTAN OHSU', 'syn39142015', 5), (NULL, 'unknown', '0.0', 'e5e37db5-1eb6-4bf8-b763-441c31740b09', NULL, 'Biopsy 1', NULL, NULL, NULL, NULL, NULL, NULL, 'BreastCancerTier3', NULL, NULL, 'Negative', NULL, NULL, NULL, NULL, NULL, NULL, 'HTA9_10', NULL, '0.0', NULL, NULL, NULL, NULL, 'Negative', NULL, NULL, NULL, NULL, NULL, NULL, 'Negative', '26205', 'HTAN OHSU', 'syn39142015', 5), (NULL, 'unknown', '0.0', 'c4be5bb4-b21e-4aeb-8d52-db2556ea72a8', NULL, 'Biopsy 2', NULL, NULL, NULL, NULL, NULL, NULL, 'BreastCancerTier3', NULL, NULL, 'Negative', NULL, NULL, NULL, NULL, NULL, NULL, 'HTA9_10', NULL, '0.0', NULL, NULL, NULL, NULL, 'Negative', NULL, NULL, NULL, NULL, NULL, NULL, 'Negative', '26248', 'HTAN OHSU', 'syn39142015', 5);