= (select to_number (« »+ cNumber + «»)) »;. Load (Comand.ExecuteReader ());
кнігуToolStripMenuItem_Click (sender, e);
} void кнігуToolStripMenuItem_Click (object sender, EventArgs e)
{AB=new AddBook (OC, null);. Show ();
} void обновітьToolStripMenuItem_Click (object sender, EventArgs e)
{();
} void екземплярToolStripMenuItem_Click (object sender, EventArgs e)
{AC=new AddCopy (OC, isbn, 0);. Show ();
} void dataGridView1_RowHeaderMouseDoubleClick (object sender, DataGridViewCellMouseEventArgs e)
{= true;=dataGridView1 [0, e.RowIndex]. Value.ToString ();
екземплярToolStripMenuItem.Visible=true; Comand=OC.CreateCommand (); tab=new DataTable ();=new DataTable ();. CommandText=«SELECT C. " cNumber " AS Номер , C. " cCost " AS Ціна, C. " cDate " AS Дата_поставкі, case when C. " cLost "=0 then «ні» else «так» end AS Утерян, » +
«case when C. " cLost " = 1 AND C. " repCode " IS NOT NULL then« так » when C. " cLost "=1 AND C. " repCode " IS NULL then «ні» else « » end AS Замінений, » +
«case when C. " woCode " IS NULL then« ні » else «так» end AS Списаний, » +
«P. " plSection " AS Відділ, P. " plRack " AS Стелаж, P. " plShelf " AS Полка, P. " plSector " AS Сектор» ; +
«FROM " Book " B INNER JOIN " Copy " C ON B.ISBN=C.ISBN AND B.ISBN=(select to_char (« »+ isbn +« ; ») from dual)» +
«INNER JOIN " Place " P ON C. " plCode " = P. " plCode " »;. Load (Comand.ExecuteReader ());. DataSource= tab.DefaultView;
} void чітателяToolStripMenuItem_Click (object sender, EventArgs e)
{AR=new AddReader (OC, 0);. Show ();
} void редактіроватьToolStripMenuItem_Click (object sender, EventArgs e)
{(mode == 1)
{AB=new AddBook (OC, isbn);. Show ();
} if (mode ==2)
{AC=new AddCopy (OC, isbn, cNumber);. Show ();
} if (mode == 3)
{AR=new AddReader (OC, rNumber);. Show ();
}. Show («Виділіть об'єкт для редагування»);
}
}
}
Клас AddReaderSystem;System.Collections.Generic;System.ComponentModel;System.Data;System.Drawing;System.Linq;System.Text;System.Threading.Tasks;System.Windows.Forms;System.Data.OracleClient;DBLibrary
{partial class AddReader: Form
{OracleConnection OC; int rNumber; bool rflag; AddReader (OracleConnection oc, int r)
{();=oc;=false; (r!=0)
{= r;=true;
}
} void button2_Click (object sender, EventArgs e)
{(textBox1.Text == null | | textBox1.Text == «» | |. Text == null | | textBox2.Text == «» | |. Text==null | | textBox5.Text =="")
{. Show («Всі поля повинні бути заповнені!");;
} ts=DateTime.Today - dateTimePicker1.Value; (ts.Days <6574)