diff --git a/DATabase/Generate.cs b/DATabase/Generate.cs index 94e2dd2d..a6f17362 100644 --- a/DATabase/Generate.cs +++ b/DATabase/Generate.cs @@ -72,6 +72,8 @@ namespace SabreTools if (_systems != "") { string query = "SELECT manufacturer, system FROM systems WHERE id in (" + _systems + ")"; + //string query = "SELECT manufacturer, name FROM system WHERE id in (" + _systems + ")"; + using (SqliteConnection dbc = new SqliteConnection(_connectionString)) { dbc.Open(); @@ -114,6 +116,7 @@ namespace SabreTools if (_sources != "") { string query = "SELECT name FROM sources WHERE id in (" + _sources + ")"; + //string query = "SELECT name FROM source WHERE id in (" + _sources + ")"; using (SqliteConnection dbc = new SqliteConnection(_connectionString)) { diff --git a/DATabase/Import.cs b/DATabase/Import.cs index 4b5b8624..0d2cac2e 100644 --- a/DATabase/Import.cs +++ b/DATabase/Import.cs @@ -631,6 +631,7 @@ COMMIT;"; INSERT OR IGNORE INTO hashdata (hashid, key, value) VALUES " + "(" + hashid + ", 'name', '" + rom.Name.Replace("'", "''") + "'), " + "(" + hashid + ", 'game', '" + rom.Game.Replace("'", "''") + "'), " + + "(" + hashid + ", 'type', '" + rom.Type + "'), " + "(" + hashid + ", 'lastupdated', '" + date + @"'); INSERT OR IGNORE INTO gamesystem (game, systemid) VALUES ('" + rom.Game.Replace("'", "''") + "', " + sysid + @"); INSERT OR IGNORE INTO gamesource (game, sourceid) VALUES ('" + rom.Game.Replace("'", "''") + "', " + srcid + @");