Mega Class Database (Oracle) v 1.0

Mega Class Database (Oracle) v 1.0 Created by themearabia. This templates have specific characteristics, namely: Use every feature of Oracle in PHP .

You can use this Mega Class Database (Oracle) v 1.0 on Php scripts category for class, class oracle, database, database oracle, mega class, oracle and another uses.

Mega Class Database (Oracle) v 1.0
© Copyright by themearabia

Features:

  • None: None
  • None: None
  • Php 4.x, php 5.x: PHP 4.x, PHP 5.x
  • None: None
  • Html, php: HTML, PHP
  • None: None

Mega Class Database (Oracle) v 1.0

Use every feature of Oracle in PHP .

Main Features:

1. Oracle Compatible.
2. Easy to Use, clean, easy to understand code.
3. Access Oracle Database without any knowledge of Oracle.
4. Uses Associative array of data to insert and update rows in the database table.
5. Optional escape string feature to avoid Oracle Injections.
6. Automatically Creates Prepared Statements.
7. Select Rows, Columns, Variables with one-liners.
8. Easy Select, Insert, Update, Delete, filtered
9. Properly documented with examples and comments.
10. Small Size.
11. Attach Fully Documented.

Functions

// Connect to serversql_connect($sqlserver, $sqluser, $sqlpassword, $database, $port = false, $persistency = false, $new_link = false);//-----------------------------------------------------------------+sql_query($query = '');// Build sql statement from array for select and select distinct statements//-----------------------------------------------------------------+// Build LIMIT querysql_query_limit($query, $total, $offset = 0);//-----------------------------------------------------------------+// Fetch current rowsql_fetchrow($query_id);//-----------------------------------------------------------------+//Possible query values: SELECT, SELECT_DISTINCTfunction sql_build_query($query, $array);//-----------------------------------------------------------------+// Run more than one insert statement.sql_multi_insert($table, &$sql_ary);//-----------------------------------------------------------------+// Escape string used in sql querysql_escape();//-----------------------------------------------------------------+// Gets some information about the specified table.get_table_status($table_name);//-----------------------------------------------------------------+// Gets the exact number of rows in a specified table.get_row_count($table_name);//-----------------------------------------------------------------+//Gets the estimated number of rows in a specified table.get_estimated_row_count($table_name);//-----------------------------------------------------------------+// display sql error pagesql_error();//-----------------------------------------------------------------+// Build IN or NOT IN sql comparison string, uses <> or = on single elementsql_in_set($field, $array, $negate = false, $allow_empty_set = false);//-----------------------------------------------------------------+// Correctly adjust LIKE expression for special characterssql_like_expression($expression);//-----------------------------------------------------------------+// Version information about used databasesql_server_info();//-----------------------------------------------------------------+// Return number of affected rowssql_affectedrows();//-----------------------------------------------------------------+// Seek to given row numbersql_rowseek($rownum, &$query_id);//-----------------------------------------------------------------+// Get last inserted id after insert statementsql_nextid();//-----------------------------------------------------------------+// Free sql resultsql_freeresult($query_id = false);//-----------------------------------------------------------------+// close sql connectionsql_close();//-----------------------------------------------------------------+

Usage

// define class file in your script.define('IN_MEGA_DB', true);// Include class file in your script.include('mega.class.database.php');$dbhost      = '';$dbport      = '';$dbname      = '';$dbuser      = '';$dbpasswd    = '';$tableprefix = '';$db     = new dbal_oracle();// connect Database$con = $db->sql_connect($dbhost, $dbuser, $dbpasswd, $dbname, $dbport);

Version History

 v1.0Initial version.