text: const Config = require('./config')
  
  const initDb = {
      async init(){
  
          const db = await Config()
  
          await db.exec(`CREATE TABLE profile (
              id INTEGER PRIMARY KEY AUTOINCREMENT,
              name TEXT, 
              avatar TEXT, 
              monthly_budget INT,
              days_per_week INT,
              hours_per_day INT,
              vacation_per_year INT,
              value_hour INT            
          )`); // << Database data can't have '-', it has to be '_'
  
          await db.exec(`CREATE TABLE jobs (
              id INTEGER PRIMARY KEY AUTOINCREMENT,
              name TEXT, 
              daily_hours INT,
              total_hours INT,
              created_at DATETIME
          )`);
  
          await db.run(`INSERT INTO profile (
              name, 
              avatar, 
              monthly_budget, 
              days_per_week, 
              hours_per_day, 
              vacation_per_year,
              value_hour     
          ) VALUES (
              "jakeliny",
              "https://avatars.githubusercontent.com/u/66533382?v=4",
              3000,
              5,
              5,
              4,
              70                
          );`)
  
          await db.run(`INSERT INTO jobs (
              name,
              daily_hours,
              total_hours,
              created_at    
          ) VALUES (
              "Pizzaria Guloso",
              2,
              1,
              1618455626801
          );`)
  
          await db.run(`INSERT INTO jobs (
              name,
              daily_hours,
              total_hours,
              created_at    
          ) VALUES (
              "OneTwo Project",
              3,
              47,
              1618455626801
          );`)
  
          await db.close()
      }
  }
  
  initDb.init()