Ejemplo n.º 1
0
        public FrmDatabaseImportProcess(List<DataImportTable> tableList, DataBase newBase, Connector.SgbdType sgbdType, IConnector conn)
        {
            InitializeComponent();
            Cursor.Current = Cursors.WaitCursor;
            _sgbdType = sgbdType;
            _db = newBase;
            _tableList = tableList;
            _conn = conn;
            foreach (DataImportTable table in tableList)
                table.Count = conn.GetCount(table.Name);
            _columnsCount = tableList.Sum(t => t.Columns.Count);

            launch();
            Cursor.Current = Cursors.Default;
        }
Ejemplo n.º 2
0
 public FrmDatabaseImportExplorer(Connector.SgbdType sgbdType, String connectionString, DataBase db)
 {
     InitializeComponent();
     _connectionString = connectionString;
     _sgbdType = sgbdType;
     _appReader = new AppSettingsReader();
     _db = db;
     populateTreeView();
     ((DataGridViewComboBoxColumn)dgvDataType.Columns["DataTypeTargetColumn"]).DataSource = _lstDt;
     ((DataGridViewComboBoxColumn)dgvDataType.Columns["DataTypeTargetColumn"]).DisplayMember = "Name";
     ((DataGridViewComboBoxColumn)dgvDataType.Columns["DataTypeTargetColumn"]).ValueMember = "Name";
     DataGridViewTextBoxCell cell = new DataGridViewTextBoxCell();
     cell.ValueType = typeof(Int64);
     dgvDataType.Columns[5].CellTemplate = cell;
     _mapper = new DataTypeMapper(_sgbdType);
 }
Ejemplo n.º 3
0
 private void cbDbChoice_SelectedIndexChanged(object sender, EventArgs e)
 {
     hideSQLServerControls();
     hideMySqlControls();
     if ((string)cbDbChoice.SelectedItem == "SQL Server")
     {
         showSQLServerControls();
         _sgbdType = Connector.SgbdType.SqlServer;
     }
     else if ((string)cbDbChoice.SelectedItem == "Oracle")
     {
         _sgbdType = Connector.SgbdType.Oracle;
     }
     else if ((string)cbDbChoice.SelectedItem == "MySql")
     {
         showMySqlControls();
         _sgbdType = Connector.SgbdType.MySql;
     }
     else if ((string)cbDbChoice.SelectedItem == "AlgoQuest")
     {
         _sgbdType = Connector.SgbdType.AlgoQuest;
     }
 }
Ejemplo n.º 4
0
 public BaseStructGenerator(Connector.SgbdType sgbdType)
 {
     _sgbdType = sgbdType;
 }