-- DBMS: snowflake
create or replace TABLE CLINICAL_GDC_R39 (
	"submitter_id" VARCHAR(16777216),
	"case_id" VARCHAR(16777216),
	"diag__treat__count" NUMBER(38,0),
	"primary_site" VARCHAR(16777216),
	"disease_type" VARCHAR(16777216),
	"proj__name" VARCHAR(16777216),
	"proj__project_id" VARCHAR(16777216),
	"demo__demographic_id" VARCHAR(16777216),
	"demo__gender" VARCHAR(16777216),
	"demo__race" VARCHAR(16777216),
	"demo__ethnicity" VARCHAR(16777216),
	"demo__vital_status" VARCHAR(16777216),
	"demo__days_to_birth" NUMBER(38,0),
	"demo__year_of_birth" NUMBER(38,0),
	"demo__age_at_index" NUMBER(38,0),
	"demo__year_of_death" NUMBER(38,0),
	"demo__days_to_death" NUMBER(38,0),
	"demo__state" VARCHAR(16777216),
	"demo__created_datetime" NUMBER(38,0),
	"demo__updated_datetime" NUMBER(38,0),
	"exp__exposure_id" VARCHAR(16777216),
	"exp__years_smoked" NUMBER(38,0),
	"exp__pack_years_smoked" FLOAT,
	"exp__cigarettes_per_day" FLOAT,
	"exp__alcohol_history" BOOLEAN,
	"exp__state" VARCHAR(16777216),
	"exp__created_datetime" NUMBER(38,0),
	"exp__updated_datetime" NUMBER(38,0),
	"diag__diagnosis_id" VARCHAR(16777216),
	"diag__ajcc_clinical_n" VARCHAR(16777216),
	"diag__masaoka_stage" VARCHAR(16777216),
	"diag__ajcc_clinical_m" VARCHAR(16777216),
	"diag__primary_diagnosis" VARCHAR(16777216),
	"diag__primary_gleason_grade" VARCHAR(16777216),
	"diag__year_of_diagnosis" NUMBER(38,0),
	"diag__figo_stage" VARCHAR(16777216),
	"diag__days_to_diagnosis" NUMBER(38,0),
	"diag__ajcc_pathologic_m" VARCHAR(16777216),
	"diag__site_of_resection_or_biopsy" VARCHAR(16777216),
	"diag__ajcc_staging_system_edition" VARCHAR(16777216),
	"diag__icd_10_code" VARCHAR(16777216),
	"diag__age_at_diagnosis" NUMBER(38,0),
	"diag__ajcc_clinical_t" VARCHAR(16777216),
	"diag__days_to_last_follow_up" NUMBER(38,0),
	"diag__ajcc_pathologic_stage" VARCHAR(16777216),
	"diag__ann_arbor_extranodal_involvement" BOOLEAN,
	"diag__ajcc_clinical_stage" VARCHAR(16777216),
	"diag__secondary_gleason_grade" VARCHAR(16777216),
	"diag__synchronous_malignancy" BOOLEAN,
	"diag__morphology" VARCHAR(16777216),
	"diag__ajcc_pathologic_t" VARCHAR(16777216),
	"diag__igcccg_stage" VARCHAR(16777216),
	"diag__ann_arbor_clinical_stage" VARCHAR(16777216),
	"diag__ann_arbor_b_symptoms" BOOLEAN,
	"diag__prior_treatment" BOOLEAN,
	"diag__ajcc_pathologic_n" VARCHAR(16777216),
	"diag__tissue_or_organ_of_origin" VARCHAR(16777216),
	"diag__prior_malignancy" BOOLEAN,
	"diag__state" VARCHAR(16777216),
	"diag__created_datetime" NUMBER(38,0),
	"diag__updated_datetime" NUMBER(38,0),
	"state" VARCHAR(16777216),
	"created_datetime" NUMBER(38,0),
	"updated_datetime" NUMBER(38,0)
);

INSERT INTO "TCGA"."TCGA_VERSIONED"."CLINICAL_GDC_R39" (diag__ann_arbor_clinical_stage, submitter_id, diag__prior_treatment, diag__ajcc_staging_system_edition, exp__state, proj__project_id, diag__icd_10_code, demo__days_to_birth, diag__year_of_diagnosis, diag__ajcc_pathologic_t, diag__primary_diagnosis, demo__year_of_death, demo__gender, demo__race, diag__ann_arbor_b_symptoms, diag__state, diag__site_of_resection_or_biopsy, case_id, diag__prior_malignancy, demo__demographic_id, proj__name, created_datetime, demo__updated_datetime, diag__diagnosis_id, diag__ajcc_pathologic_m, exp__updated_datetime, exp__created_datetime, demo__created_datetime, diag__age_at_diagnosis, demo__state, exp__years_smoked, diag__igcccg_stage, diag__treat__count, diag__tissue_or_organ_of_origin, diag__secondary_gleason_grade, diag__morphology, exp__alcohol_history, demo__ethnicity, disease_type, exp__cigarettes_per_day, demo__age_at_index, diag__masaoka_stage, diag__updated_datetime, diag__ajcc_pathologic_stage, exp__pack_years_smoked, diag__ajcc_clinical_t, diag__synchronous_malignancy, diag__ajcc_clinical_m, diag__ajcc_clinical_n, demo__vital_status, updated_datetime, diag__days_to_last_follow_up, diag__figo_stage, diag__created_datetime, primary_site, diag__primary_gleason_grade, diag__ajcc_pathologic_n, diag__ajcc_clinical_stage, diag__days_to_diagnosis, diag__ann_arbor_extranodal_involvement, demo__year_of_birth, demo__days_to_death, state, exp__exposure_id) VALUES (NULL, 'TCGA-17-Z008', NULL, NULL, NULL, 'TCGA-LUAD', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, '631dbd88-fc3e-4ed8-b4a7-2da137a49a11', NULL, NULL, 'Lung Adenocarcinoma', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, 'Adenomas and Adenocarcinomas', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 1556730373818117, NULL, NULL, NULL, 'Bronchus and lung', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'released', NULL), (NULL, 'TCGA-17-Z005', NULL, NULL, NULL, 'TCGA-LUAD', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, '4b5ff30e-65fc-4434-b174-9d699594c658', NULL, NULL, 'Lung Adenocarcinoma', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, 'Adenomas and Adenocarcinomas', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 1556730373818117, NULL, NULL, NULL, 'Bronchus and lung', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'released', NULL), (NULL, 'TCGA-17-Z012', NULL, NULL, NULL, 'TCGA-LUAD', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'edd05f61-35f8-4133-a579-f9f32dff3bb8', NULL, NULL, 'Lung Adenocarcinoma', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, 'Adenomas and Adenocarcinomas', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 1556730373818117, NULL, NULL, NULL, 'Bronchus and lung', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'released', NULL), (NULL, 'TCGA-17-Z011', NULL, NULL, NULL, 'TCGA-LUAD', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'dcf8e752-e95c-4087-a0f5-c041787c8569', NULL, NULL, 'Lung Adenocarcinoma', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, 'Adenomas and Adenocarcinomas', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 1556730373818117, NULL, NULL, NULL, 'Bronchus and lung', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'released', NULL), (NULL, 'TCGA-17-Z006', NULL, NULL, NULL, 'TCGA-LUAD', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, '53d7b0c2-b8ed-43c8-9ffd-a586e0a68086', NULL, NULL, 'Lung Adenocarcinoma', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 0, NULL, NULL, NULL, NULL, NULL, 'Adenomas and Adenocarcinomas', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 1556730373818117, NULL, NULL, NULL, 'Bronchus and lung', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'released', NULL);