Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F95198751
00-i2b2-schemas-roles.sh
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Fri, Dec 13, 16:10
Size
603 B
Mime Type
text/x-shellscript
Expires
Sun, Dec 15, 16:10 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
22928953
Attached To
R4444 MedCo Deployment
00-i2b2-schemas-roles.sh
View Options
#!/bin/bash
set -Eeuo pipefail
# create schemas for i2b2
function initSchema {
DB_NAME="$1"
SCHEMA_NAME="$2"
psql $PSQL_PARAMS -d "$DB_NAME" <<-EOSQL
create schema $SCHEMA_NAME;
grant all on schema $SCHEMA_NAME to $I2B2_DB_USER;
grant all privileges on all tables in schema $SCHEMA_NAME to $I2B2_DB_USER;
EOSQL
}
# init demo i2b2 database
initSchema $I2B2_DB_NAME i2b2demodata_i2b2
initSchema $I2B2_DB_NAME i2b2imdata
initSchema $I2B2_DB_NAME i2b2metadata_i2b2
initSchema $I2B2_DB_NAME i2b2workdata
initSchema $I2B2_DB_NAME i2b2pm
initSchema $I2B2_DB_NAME i2b2hive
Event Timeline
Log In to Comment