-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathsql_queries.sql
67 lines (48 loc) · 3.53 KB
/
sql_queries.sql
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
CREATE TABLE IF NOT EXISTS quantumlab_experiments.experiments_metadata_jwcplc (experiment_id TEXT, experiment_run_date TEXT, status TEXT, experiment_name TEXT, experiment_description TEXT, num_qubit_space TEXT, n_simulations INT, p_space TEXT, q_space TEXT, use_constant_size BOOL, constant_size INT, subsystem_range_divider FLOAT, runtime_in_seconds FLOAT, experimental_design_type TEXT);
CREATE TABLE IF NOT EXISTS quantumlab_experiments.simulation_results_jwcplc (num_qubits INT, p FLOAT, q FLOAT, mean_entropy FLOAT, se_mean_entropy FLOAT, experiment_id TEXT, mean_runtime FLOAT);
CREATE TABLE IF NOT EXISTS quantumlab_experiments.entropy_tracking_jwcplc (experiment_id TEXT, p FLOAT, q FLOAT, simulation_number INT, num_qubits INT, bond_index INT, ij INT, eigenvalue FLOAT, entropy_contribution FLOAT);
CREATE TABLE IF NOT EXISTS quantumlab_experiments.entropy_tracking_jwcplc_copytest (experiment_id TEXT, p FLOAT, q FLOAT, simulation_number INT, num_qubits INT, bond_index INT, ij INT, eigenvalue FLOAT, entropy_contribution FLOAT);
--DROP TABLE IF EXISTS quantumlab_experiments.experiments_metadata_jwcplc;
--delete from quantumlab_experiments.experiments_metadata_jwcplc where experiment_id is not null;
--delete from quantumlab_experiments.entropy_tracking_jwcplc where experiment_id = '0x06dfa27044774ab7b9c9c484304846d1';
select *
from quantumlab_experiments.experiments_metadata
select distinct experiment_id
from quantumlab_experiments.experiments_metadata
select *
from quantumlab_experiments.simulation_results
where experiment_id = '';
select *
from quantumlab_experiments.entropy_tracking
where experiment_id = '';
select count(*) as n
from quantumlab_experiments.entropy_tracking
where experiment_id = '';
-- alter table quantumlab_experiments.experiments_metadata add column status TEXT ;
-- alter table quantumlab_experiments.experiments_metadata add column experimental_design_type TEXT;
-- update quantumlab_experiments.experiments_metadata set experimental_design_type = 'Standard Bricklayer';
-- alter table quantumlab_experiments.simulation_results add column mean_runtime FLOAT ;
-- clear data
-- delete from quantumlab_experiments.simulation_results where experiment_id is not null;
-- delete from quantumlab_experiments.entropy_tracking where experiment_id is not null;
-- delete from quantumlab_experiments.experiments_metadata where experiment_id is not null;
--delete from quantumlab_experiments.simulation_results where experiment_id = '0xbcee3e8ca662403c9609615477a6fe3b';
--delete from quantumlab_experiments.entropy_tracking where experiment_id = '0xbcee3e8ca662403c9609615477a6fe3b';
--delete from quantumlab_experiments.experiments_metadata where experiment_id = '0xbcee3e8ca662403c9609615477a6fe3b';
--delete from quantumlab_experiments.simulation_results_jwcplc where experiment_id = '0x256d038b432d44b5aea0a12f156d08dc';
select count(*) as n
from quantumlab_experiments.entropy_tracking_jwcplc where experiment_id = '0x256d038b432d44b5aea0a12f156d08dc';
select count(*) as n
from quantumlab_experiments.entropy_tracking_jwcplc;
select count(*) as n
from quantumlab_experiments.entropy_tracking_jwcplc
where num_qubits = 26
select count(*) as n
from quantumlab_experiments.simulation_results_jwcplc
where num_qubits = 26
--delete from quantumlab_experiments.entropy_tracking_jwcplc where num_qubits = 26;
--delete from quantumlab_experiments.simulation_results_jwcplc where num_qubits = 26;
select *
from quantumlab_experiments.entropy_tracking_jwcplc
where experiment_id = '0xb65fb8c7a4664c8f8ec6e4722a37ba70'
order by p,q,num_qubits,simulation_number, ij