Posts

Showing posts from February, 2012

Page Life Cycle

(1) PreInit   The entry point of the page life cycle is the pre-initialization phase called “PreInit”. This is the only event where programmatic access to master pages and themes is allowed. You can dynamically set the values of master pages and themes in this event. You can also dynamically create controls in this event.  EXAMPLE : Override the event as given below in your code-behind cs file of your aspx page (2)Init  This event fires after each control has been initialized, each control's UniqueID is set and any skin settings have been applied. You can use this event to change initialization values for controls. The “Init” event is fired first for the most bottom control in the hierarchy, and then fired up the hierarchy until it is fired for the page itself.  EXAMPLE : Override the event as given below in your code-behind cs file of your aspx page (3)InitComplete    Raised once all initializations of the page and its controls have been completed. ...

Except

Selecting records from a table, that is not existing in another table.              We can use the keyword EXCEPT example:        select   * from emp1 except select * from emp2   It will display records that exist in emp1 but not in emp2

Select

Syntax:             SELECT columns FROM tables WHERE predicates; Example:            SELECT *           FROM suppliers           WHERE city = 'Newark'; You can also use the select statement to retrieve fields from multiple tables. SELECT orders.order_id, suppliers.name FROM suppliers, orders WHERE suppliers.supplier_id = orders.supplier_id; You can select some fields from a table acoording to more than one conditions.                          If you are trying to select details of 5 students  having maximum mark from bottom of the table                       s...

select

Syntax:             SELECT columns FROM tables WHERE predicates; Example:            SELECT *           FROM suppliers           WHERE city = 'Newark'; You can also use the select statement to retrieve fields from multiple tables. SELECT orders.order_id, suppliers.name FROM suppliers, orders WHERE suppliers.supplier_id = orders.supplier_id; You can select some fields from a table acoording to more than one conditions.

Primary key

         Syntax: CREATE TABLE table_name (column1 datatype null/not null, column2 datatype null/not null, ...  PRIMARY KEY (column1, column2, . column_n) );   example: CREATE TABLE supplier ( supplier_id numeric(10) not null,   supplier_name varchar2(50) not null,   contact_name varchar2(50),     PRIMARY KEY (supplier_id) ); Using an ALTER TABLE statement   Syntax:           ALTER TABLE table_name          add PRIMARY KEY (column1, column2, ... column_n);  Example: ALTER TABLE supplier add CONSTRAINT supplier_pk PRIMARY KEY (supplier_id);

Create,Alter,Modify

Image
 Syntax: CREATE TABLE table_name ( column1 datatype null/not null,   column2 datatype null/not null,   ... );   Example          CREATE TABLE EMPLOYEE_DETAILS(EMPNAME VARCHAR2(20),EMPAGE INT,EMPSALARY NUMERIC(6,2),EMPDESIGNATION VARCHAR2(20)) OutPut                                  We can edit the structure of a table by using a keyword 'ALTER'.                    Renaming a table  syntax :     ALTER TABLE table_name   RENAME TO new_table_name;  example: ALTER TABLE suppliers  RENAME TO vendors; This will rename the suppliers table to vendors . Adding column(s) to a table Syntax :   ...

Insert

Image
      Syntax: INSERT INTO table (column-1, column-2, ... column-n) VALUES (value-1, value-2, ... value-n);                      If we are inserting datas to entire fields then no need to specify the fieldnames.        Example:                                   INSERT INTO EMPLOYEE_DETAILS    VALUES('Akhilash',22,2500,'Developer');          INSERT INTO EMPLOYEE_DETAILS    VALUES('Akhilash',22,250.90,'Developer');     INSERT INTO EMPLOYEE_DETAILS    VALUES('Akhilash',22,250.90,'Developer');     OutPut             ...

Introduction To Oracle10g

                                                  Oracle Database 10 g, released in 2003 and the current release, enables grid (the g in 10g) computing. A grid is simply a pool of computers that provides needed resources for applications on an as-needed basis. The goal is to provide computing resources that transparently scale to the user community, much as an electrical utility company can deliver power to meet peak demand by accessing energy from other power providers’ plants via a power grid. Oracle Database 10 g further reduces the time, cost, and complexity of database management through the introduction of self-managing features such as the Automated Database Diagnostic Monitor, Automated Shared Memory Tuning, Automated Storage Management, and Automa...