Insert into Oracle Database
Code:
protected void Page_Load(object sender, EventArgs e)
{
int Roll = 1;
string sName = " powerful personalized interfaces by simply dragging and dropping pre-defined Web Part Components. Web Parts are components that enable non programmers to gather information they care about and customize the appearance of Web pages. For exampleharePoint allows information workers to create powerful personalized interfaces by simply dragging and dropping pre-defined Web Part Components. Web Parts are components that enable non programmers to gather information they care about and customize the appearance of Web pages. For exampleharePoint allows information workers to create powerful personalized interfaces by simply dragging and dropping pre-defined Web Part Components. Web Parts are components that enable non programmers to gather information they care about and customize the appearance of Web pages. For exampleharePoint allows information workers to create powerful personalized interfaces by simply dragging and dropping pre-defined Web Part Components. Web Parts are components that enable non programmers togather information they care about and customize the appearance of Web pages. For examplev11harePoint allows information workers to create powerful personalized interfaces by simply dragging and dropping pre-defined Web Part Components. Web Parts are components that enable non programmers to gather information they care about and customize the appearance of Web pages. For exampleharePoint allows information workers to create powerful personalized interfaces by simply dragging and dropping pre-defined Web Part Components. Web Parts are components that enable non programmers to gather information they care about and customize the appearance of Web pages. For examplevharePoint allows information workers to create powerful personalized interfaces by simply dragging and dropping pre-defined Web Part Components. Web Parts are components that enable non programmers to gather information they care about and customize the appearance of Web pages. For examplevvharePoint allows information workers to create powerful pers onalized interfaces by simply dragging and dropping pre-defined Web Part Components. Web Parts are components that enable non programmers to gather information they care about and customize the appearance of Web pages. For exampleharePoint allows information workers to create powerful personalized interfaces by simply dragging and dropping pre-defined Web Part Components. Web Parts are components that enable non programmers to gather information they care about and customize the appearance of Web pages. For exampleharePoint allows information workers to create powerful personalized interfaces by simply dragging and dropping pre-defined Web Part Components. Web Parts are components that enable non programmers to gather information they care about and customize the appearance of Web pages. For exampleharePoint allows information workers to create powerful personalized interfaces by simply dragging and dropping pre-defined Web Part Components. Web Parts are components that enable non programmers to gather informa tion they care about and customize the appearance of Web pages. For exampleharePoint allows information workers to create powerful personalized interfaces by simply dragging and dropping pre-defined Web Part Components. Web Parts are components that enable non programmers to gather information they care about and customize the appearance of Web pages. For exampleharePoint allows information workers to create powerful personalized interfaces by simply dragging and dropping pre-defined Web Part Components. Web Parts are components that enable non programmers to gather information they care about and customize the appearance of Web pages. For exampleharePoint allows information workers to create powerful personalized interfaces by simply dragging and dropping pre-defined W";
string sQuery = "INSERT INTO TBL_STUDENT(ROLL,NAME1) VALUES (" + Roll + " ,'" + sName + "')";
if (con.State == ConnectionState.Closed)
{
con.Open();
}
OracleCommand cmd = new OracleCommand(sQuery,con);
cmd.ExecuteNonQuery();
}
DataType of NAME1 column is VARCHAR2(4000 CHAR).
1) Can somebody tell me in Oracle for VARCHAR2 ,we have two datatypes CHAR & BYTE. Wats the diffence between Two.
If we choose 4000 CHAR,Maximum number of characters that can be insrted in database is 4000 chracters.SUppose I choose the 20 Byte,how many chracters can be insrted in database?
2) If I want to insert more than 4000 characters,Which DataType to USE??
Re: Insert into Oracle Database
Hey,
Again, this question doesn't really belong in the ASP.Net forum, as this is very much a database (in your case Oracle) question.
I am going to ask that this be moved to the appropriate forum.
Gary
Re: Insert into Oracle Database
Thread moved to 'Database Development' forum
(thanks for letting us know Gary :thumb: )
Re: Insert into Oracle Database
The difference between byte and char length only matters for character sets that use more than 1 byte per character, e.g. for WE8ISO8859P1 they are the same (1 byte = 1 char). For multi-byte character sets, since varchar2 max length in tables is 4000 bytes you can end up with 2000 (2 byte per char) or less characters (more than 2 bytes per character).