noalyss Version-9
|
This class allow you to connect to the postgresql database, execute sql, retrieve data. More...
Public Member Functions | |
__construct ($p_user, $p_password, $p_dbname, $p_host, $p_port) | |
__toString () | |
alter_seq ($p_name, $min) | |
alter the sequence value More... | |
clean_orphan_lob () | |
Find all lob and remove those which are not used by any tables. More... | |
clear_all_prepare () | |
clear all prepare stmt More... | |
clear_prepare ($sql_name) | |
clear a prepare stmt More... | |
close () | |
wrapper for the function pg_close More... | |
commit () | |
Commit the transaction. More... | |
count ($p_ret=null) | |
synomym for size() More... | |
count_sql ($p_sql, $p_array=null) | |
Count the number of row returned by a sql statement. More... | |
create_sequence ($p_name, $min=1) | |
Create a sequence. More... | |
exec_sql ($p_string, $p_array=null) | |
send a sql string to the database More... | |
execute ($p_string, $p_array) | |
wrapper for the function pg_execute More... | |
execute_script ($script) | |
Execute a sql script. More... | |
exist_blob ($p_oid) | |
check if the large object exists More... | |
exist_column ($col, $table, $schema) | |
Check if a column exists in a table. More... | |
exist_database ($p_name) | |
Count the database name in a system view. More... | |
exist_schema ($p_name) | |
exist_sequence ($p_name) | |
test if a sequence exist More... | |
exist_table ($p_name, $p_schema='public') | |
test if a table exist More... | |
exist_view ($p_name) | |
fetch ($p_indice) | |
fetch the $p_indice array from the last query More... | |
get_affected () | |
return the number of rows affected by the previous query More... | |
get_array ($p_sql, $p_array=null) | |
purpose return the result of a sql statment in a array More... | |
get_current_seq ($p_seq) | |
get the current sequence value More... | |
get_db () | |
get_encoding () | |
get_is_open () | |
get_name () | |
return the name of the current database More... | |
get_next_seq ($p_seq) | |
get the next sequence value More... | |
get_ret () | |
get_row ($p_sql, $p_array=NULL) | |
Returns only one row from a query. More... | |
get_sql () | |
last SQL stmt executed More... | |
get_value ($p_sql, $p_array=null) | |
return the value of the sql, the sql will return only one value with the value More... | |
is_prepare ($query_name) | |
Check if a prepared statement already exists or not. More... | |
lo_export ($p_oid, $tmp_file) | |
wrapper for the function pg_lo_export More... | |
lo_import ($p_filename) | |
wrapper for the function pg_lo_export More... | |
lo_unlink ($p_oid) | |
wrapper for the function pg_lo_unlink More... | |
make_array ($p_sql, $p_null=0, $p_array=null) | |
make a array with the sql. More... | |
make_list ($sql, $p_array=null) | |
create a string containing the value separated by comma for use in a SQL in statement More... | |
prepare ($p_string, $p_sql) | |
wrapper for the function pg_prepare More... | |
query_to_csv ($ret, $aheader) | |
with the handle of a successull query, echo each row into CSV and send it directly More... | |
rollback () | |
rollback the current transaction More... | |
search_sql_inject ($p_sql) | |
FInd if a SQL Select has a SQL stmt to inject or damage Data When a SELECT SQL string is build, this string could contain a SQL attempt to damage data, so the statement DELETE TRUNCATE ... are forbidden. More... | |
set_db ($db) | |
set_encoding ($p_charset) | |
set_is_open ($is_open) | |
set_ret ($ret) | |
set_sql ($sql) | |
last SQL stmt executed More... | |
size ($p_ret=null) | |
return the number of rows found by the last query, or the number of rows from $p_ret More... | |
start () | |
: start a transaction More... | |
status () | |
get the transaction status : The status can be More... | |
upload ($p_name) | |
verify () | |
Static Public Member Functions | |
static | escape_string ($p_string) |
wrapper for the function pg_escape_string More... | |
static | fetch_all ($ret) |
wrapper for the function pg_fetch_all More... | |
static | fetch_array ($ret, $p_indice=0, $p_mode=PGSQL_ASSOC) |
wrapper for the function pg_fetch_array More... | |
static | fetch_result ($ret, $p_row=0, $p_col=0) |
wrapper for the function pg_fetch_all More... | |
static | fetch_row ($ret, $p_row) |
wrapper for the function pg_fetch_row More... | |
static | nb_column ($p_ret) |
Returns the number of columns in a ret. More... | |
static | num_row ($ret) |
wrapper for the function pg_num_rows More... | |
static | test_me () |
Data Fields | |
$array | |
$sql | |
last SQL stmt executed More... | |
Private Attributes | |
$db | |
database connection More... | |
$is_open | |
$ret | |
return value More... | |
This class allow you to connect to the postgresql database, execute sql, retrieve data.
Definition at line 35 of file database_core.class.php.
DatabaseCore::__construct | ( | $p_user, | |
$p_password, | |||
$p_dbname, | |||
$p_host, | |||
$p_port | |||
) |
Definition at line 54 of file database_core.class.php.
References db.
DatabaseCore::__toString | ( | ) |
return
Definition at line 889 of file database_core.class.php.
DatabaseCore::alter_seq | ( | $p_name, | |
$min | |||
) |
alter the sequence value
$p_name | name of the sequence |
$min | the start value of the sequence |
Definition at line 292 of file database_core.class.php.
References $min, $Res, and exec_sql().
Referenced by Database\apply_patch().
DatabaseCore::clean_orphan_lob | ( | ) |
Find all lob and remove those which are not used by any tables.
Definition at line 920 of file database_core.class.php.
References $check, $i, $sql, count(), get_array(), get_value(), and lo_unlink().
DatabaseCore::clear_all_prepare | ( | ) |
DatabaseCore::clear_prepare | ( | $sql_name | ) |
clear a prepare stmt
$sql_name | name of the prepare SQL |
Definition at line 1035 of file database_core.class.php.
References db, and escape_string().
DatabaseCore::close | ( | ) |
wrapper for the function pg_close
Definition at line 875 of file database_core.class.php.
References db.
DatabaseCore::commit | ( | ) |
Commit the transaction.
Definition at line 272 of file database_core.class.php.
References $Res, and exec_sql().
DatabaseCore::count | ( | $p_ret = null | ) |
synomym for size()
Definition at line 417 of file database_core.class.php.
References size().
Referenced by clean_orphan_lob(), get_row(), make_list(), and query_to_csv().
DatabaseCore::count_sql | ( | $p_sql, | |
$p_array = null |
|||
) |
Count the number of row returned by a sql statement.
$p_sql | sql string |
$p_array | if not null we use the safer pg_query_params |
Definition at line 232 of file database_core.class.php.
References $p_array, and exec_sql().
Referenced by exist_schema(), exist_sequence(), exist_table(), and exist_view().
DatabaseCore::create_sequence | ( | $p_name, | |
$min = 1 |
|||
) |
Create a sequence.
string | $p_name | Sequence Name |
int | $min | starting value |
Definition at line 502 of file database_core.class.php.
References $min, $sql, and exec_sql().
|
static |
wrapper for the function pg_escape_string
$p_string | is the string to escape |
Definition at line 864 of file database_core.class.php.
References $cn.
Referenced by clear_prepare(), Noalyss_User\connect_user(), Acc_Account_Ledger\get_used_accounting(), Anc_Acc_List\load_anc_account(), Anc_Acc_List\load_anc_card(), Anc_Acc_List\load_card(), Anc_Table\load_card(), Anc_Acc_List\load_poste(), Anc_Table\load_poste(), Follow_Up\myList(), and Noalyss_User\set_session_var().
DatabaseCore::exec_sql | ( | $p_string, | |
$p_array = null |
|||
) |
send a sql string to the database
$p_string | sql string |
$p_array | array for the SQL string (see pg_query_params) |
Definition at line 180 of file database_core.class.php.
References $a, $p_array, $ret, db, record_log(), and rollback().
Referenced by Database\__construct(), alter_seq(), Database\apply_patch(), Extension\clean(), commit(), count_sql(), create_sequence(), execute_script(), get_array(), get_next_seq(), get_value(), Sendmail\increment_mail(), make_array(), rollback(), Database\save_receipt(), and start().
DatabaseCore::execute | ( | $p_string, | |
$p_array | |||
) |
wrapper for the function pg_execute
$p_string | string name of the stmt given in pg_prepare function |
$p_array | contains the variables |
Definition at line 828 of file database_core.class.php.
DatabaseCore::execute_script | ( | $script | ) |
Execute a sql script.
$script | script name |
Definition at line 304 of file database_core.class.php.
References $script, $sql, exec_sql(), print, and rollback().
Referenced by Database\apply_patch().
DatabaseCore::exist_blob | ( | $p_oid | ) |
check if the large object exists
$p_oid | of the large object |
Definition at line 571 of file database_core.class.php.
References $r, and get_value().
Referenced by lo_unlink().
DatabaseCore::exist_column | ( | $col, | |
$table, | |||
$schema | |||
) |
Check if a column exists in a table.
$col | : column name |
$table | :table name |
$schema | :schema name, default public |
Definition at line 545 of file database_core.class.php.
References $r, $table, and get_value().
DatabaseCore::exist_database | ( | $p_name | ) |
Count the database name in a system view.
$p_name | string database name |
Definition at line 559 of file database_core.class.php.
References get_value().
DatabaseCore::exist_schema | ( | $p_name | ) |
Definition at line 599 of file database_core.class.php.
References $r, and count_sql().
Referenced by Database\__construct(), Database\apply_patch(), and Extension\clean().
DatabaseCore::exist_sequence | ( | $p_name | ) |
test if a sequence exist
Definition at line 515 of file database_core.class.php.
References $r, and count_sql().
DatabaseCore::exist_table | ( | $p_name, | |
$p_schema = 'public' |
|||
) |
test if a table exist
$p_name | table name |
$schema | name of the schema default public |
Definition at line 530 of file database_core.class.php.
References $r, and count_sql().
Referenced by Database\apply_patch().
DatabaseCore::exist_view | ( | $p_name | ) |
Definition at line 586 of file database_core.class.php.
References $r, and count_sql().
DatabaseCore::fetch | ( | $p_indice | ) |
fetch the $p_indice array from the last query
$p_indice | index |
Definition at line 389 of file database_core.class.php.
|
static |
wrapper for the function pg_fetch_all
$ret | is the result of pg_exec (exec_sql) |
Definition at line 768 of file database_core.class.php.
References $ret.
Referenced by Acc_Ledger_History\add_additional_tax_info(), Acc_Ledger_History_Purchase\add_vat_info(), Acc_Ledger_History_Sale\add_vat_info(), Fiche\belong_ledger(), Follow_Up\get(), Table_Data_SQL\get_all_to_array(), Anc_Operation\get_balance(), Acc_Ledger\get_class_def(), Acc_Ledger_History_Generic\get_detail(), Acc_Ledger\get_fiche_def(), Anc_Operation\get_jrid(), Acc_Operation\get_jrnx_detail(), Anc_Operation\get_list(), Anc_Plan\get_list(), Acc_Report\get_list(), Pre_operation\get_list_ledger(), Fiche\get_quick_code(), Acc_Reconciliation\get_reconciled_amount(), Acc_Ledger_History_Generic\get_row(), Acc_Account_Ledger\get_row_date(), Acc_Ledger_History_Generic\get_rowSimple(), Acc_Ledger\get_solde(), Fiche\getName(), Pre_op_ach\load(), Pre_Op_Advanced\load(), Pre_op_ods\load(), Pre_op_ven\load(), Acc_Account_Ledger\load(), Anc_Balance_Simple\load(), Pre_op_fin\load(), Pre_operation\load(), Acc_Ledger_Info\load_all(), Acc_Parm_Code\load_all(), Todo_List\load_all(), Follow_Up\myList(), Anc_Group\myList(), Document_modele\myList(), Follow_Up\short_list(), and Customer\VatListing().
|
static |
wrapper for the function pg_fetch_array
$ret | is the result of a pg_exec |
$p_indice | is the index |
$p_indice | is the index |
Definition at line 757 of file database_core.class.php.
References $ret.
Referenced by Noalyss_Parameter_Folder\__construct(), Card_Property\build_input(), Noalyss_User\Check(), Document_modele\Delete(), Manage_Table_SQL\display_table(), Periode_Ledger_Table\display_table(), Fiche_Def\DisplayAttribut(), Print_Ledger_Detail_Item\export(), Print_Ledger_Simple\export(), Print_Ledger_Simple_Without_Vat\export(), Acc_Ledger_History_Purchase\export_csv(), Acc_Ledger_History_Sale\export_csv(), Follow_Up\export_csv_detail(), Document\export_file(), Acc_Operation\find_tiers(), Document\generate(), Acc_Reconciliation\get(), Anc_Plan\get(), Document\get(), Document_Type\get(), Fiche_Def\get(), Fiche_Def\get_all(), Acc_Reconciliation\get_amount_noautovat(), Fiche_Def\get_attr_min(), Fiche\get_bk_balance(), Customer\get_by_account(), Supplier\get_by_account(), Fiche_Def\get_by_category(), Fiche\get_by_category(), Acc_Operation\get_data(), Periode\get_date_limit(), Acc_Operation\get_internal(), Acc_Account_Ledger\get_name(), Acc_Ledger\get_name(), Acc_Report\get_row(), Fiche\get_row_result_deprecated(), Acc_Account_Ledger\get_row_sql_deprecated(), Acc_Account_Ledger\get_solde(), Acc_Account_Ledger\get_solde_detail(), Fiche\get_solde_detail(), Acc_Ledger\get_type(), Fiche_Def\getAttribut(), html_min_page_start(), html_page_start(), isValid_deprecrated(), Acc_Ledger_Search\list_operation(), Acc_Ledger_Search\list_operation_to_reconcile(), Acc_Ledger\listing(), Acc_Bilan\load(), Acc_Ledger_Info\load(), Acc_Parm_Code\load(), Acc_Payment\load(), Anc_Group\load(), Dossier\load(), Forecast\load(), Noalyss_User\load(), Todo_List\load(), Card_Property\load(), Fiche_Def\myList(), query_to_csv(), Document_modele\Save(), Document\send(), Profile_Menu\sub_menu(), Document_modele\update(), Card_Property\update(), Anc_Operation\update_from_jrnx(), Dossier\upgrade(), Customer\VatListing(), Acc_Bilan\verify(), and Acc_Bilan\warning().
|
static |
wrapper for the function pg_fetch_all
$ret | is the result of pg_exec (exec_sql) |
$p_row | is the indice of the row |
$p_col | is the indice of the col |
Definition at line 781 of file database_core.class.php.
Referenced by Fiche\empty_attribute(), Print_Ledger_Financial\export(), Periode\find_periode(), Periode\get_exercice(), Acc_Account_Ledger\get_row(), Fiche\get_row(), Fiche\get_row_date(), Acc_Ledger_Info\insert(), Forecast\insert(), Todo_List\insert(), Periode\is_centralized(), Periode\is_closed(), Acc_Ledger_Info\search_id_internal(), and Acc_Operation\seek_internal().
|
static |
wrapper for the function pg_fetch_row
$ret | is the result of pg_exec (exec_sql) |
$p_row | is the indice of the row |
Definition at line 792 of file database_core.class.php.
References $ret.
Referenced by Html_Table\sql2table().
DatabaseCore::get_affected | ( | ) |
return the number of rows affected by the previous query
Definition at line 459 of file database_core.class.php.
References num_row().
DatabaseCore::get_array | ( | $p_sql, | |
$p_array = null |
|||
) |
purpose return the result of a sql statment in a array
$p_sql | sql query |
$p_array | if not null we use ExecSqlParam |
Definition at line 472 of file database_core.class.php.
References $array, $p_array, $r, and exec_sql().
Referenced by clean_orphan_lob(), get_row(), and make_list().
DatabaseCore::get_current_seq | ( | $p_seq | ) |
get the current sequence value
Definition at line 242 of file database_core.class.php.
References $Res, and get_value().
DatabaseCore::get_db | ( | ) |
DatabaseCore::get_encoding | ( | ) |
Definition at line 101 of file database_core.class.php.
References db.
DatabaseCore::get_is_open | ( | ) |
Definition at line 142 of file database_core.class.php.
References $is_open.
DatabaseCore::get_name | ( | ) |
return the name of the current database
Definition at line 87 of file database_core.class.php.
DatabaseCore::get_next_seq | ( | $p_seq | ) |
get the next sequence value
Definition at line 252 of file database_core.class.php.
References $Res, $seq, and exec_sql().
DatabaseCore::get_ret | ( | ) |
DatabaseCore::get_row | ( | $p_sql, | |
$p_array = NULL |
|||
) |
Returns only one row from a query.
string | $p_sql | |
array | $p_array |
Exception | if too many rows are found code 100 |
Definition at line 489 of file database_core.class.php.
References $array, $p_array, count(), and get_array().
DatabaseCore::get_sql | ( | ) |
last SQL stmt executed
string | $sql |
Definition at line 158 of file database_core.class.php.
References $sql.
DatabaseCore::get_value | ( | $p_sql, | |
$p_array = null |
|||
) |
return the value of the sql, the sql will return only one value with the value
$p_sql | the sql stmt example :select s_value from document_state where s_id=2 |
$p_array | if array is not null we use the ExecSqlParm (safer) |
Definition at line 436 of file database_core.class.php.
References $array, $ex, $p_array, $r, and exec_sql().
Referenced by Acc_Account\__construct(), Database\apply_patch(), clean_orphan_lob(), exist_blob(), exist_column(), exist_database(), get_current_seq(), Sendmail\get_email_sent(), Sendmail\get_max_email(), Database\get_version(), and is_prepare().
DatabaseCore::is_prepare | ( | $query_name | ) |
Check if a prepared statement already exists or not.
string | $query_name | name of the prepared query |
Definition at line 963 of file database_core.class.php.
References get_value().
DatabaseCore::lo_export | ( | $p_oid, | |
$tmp_file | |||
) |
wrapper for the function pg_lo_export
$p_oid | is the oid of the log |
$tmp_file | is the file |
Definition at line 841 of file database_core.class.php.
References db.
DatabaseCore::lo_import | ( | $p_filename | ) |
wrapper for the function pg_lo_export
$p_filename | is the filename |
$tmp | is the file |
Definition at line 853 of file database_core.class.php.
References db.
DatabaseCore::lo_unlink | ( | $p_oid | ) |
wrapper for the function pg_lo_unlink
$p_oid | is the of oid |
Definition at line 803 of file database_core.class.php.
References db, and exist_blob().
Referenced by clean_orphan_lob(), and Database\save_receipt().
DatabaseCore::make_array | ( | $p_sql, | |
$p_null = 0 , |
|||
$p_array = null |
|||
) |
make a array with the sql.
$p_sql | sql statement, only the first two column will be returned in an array. The first col. is the label and the second the value |
$p_null | if the array start with a null value Yes = 1 , No=0 |
$p_array | is the array with the bind value |
* Array * ( * [0] => Array * ( * [value] => 1 * [label] => Marchandise A * ) * * [1] => Array * ( * [value] => 2 * [label] => Marchandise B * ) * * [2] => Array * ( * [value] => 3 * [label] => Marchandise C * ) * ) *
Definition at line 671 of file database_core.class.php.
References $a, $i, $max, $p_array, $r, $row, exec_sql(), and h.
DatabaseCore::make_list | ( | $sql, | |
$p_array = null |
|||
) |
create a string containing the value separated by comma for use in a SQL in statement
Definition at line 614 of file database_core.class.php.
References $f, $i, $idx, $p_array, $ret, $row, $sql, count(), and get_array().
|
static |
Returns the number of columns in a ret.
handler | $p_ret | handler to a query |
Definition at line 1006 of file database_core.class.php.
Referenced by Export_Data_PDF\__construct().
|
static |
wrapper for the function pg_num_rows
$ret | is the result of a exec_sql |
Definition at line 744 of file database_core.class.php.
References $ret.
Referenced by Noalyss_Parameter_Folder\__construct(), Default_Menu\__construct(), Fiche\belong_ledger(), Noalyss_User\Check(), Data_SQL\collect_objects(), Periode\display_periode_global(), Manage_Table_SQL\display_table(), Periode_Ledger_Table\display_table(), Fiche_Def\DisplayAttribut(), Acc_Account_Ledger\do_exist(), Fiche\empty_attribute(), Acc_Report\exist(), Export_Data_PDF\export(), Print_Ledger_Detail_Item\export(), Print_Ledger_Simple\export(), Print_Ledger_Simple_Without_Vat\export(), Follow_Up\export_csv(), Acc_Ledger_History_Purchase\export_csv(), Acc_Ledger_History_Sale\export_csv(), Follow_Up\export_csv_detail(), Document\export_file(), Periode\find_periode(), Acc_Operation\find_tiers(), Acc_Reconciliation\get(), Anc_Plan\get(), Document\get(), Fiche_Def\get(), get_affected(), Fiche_Def\get_all(), Acc_Reconciliation\get_amount_noautovat(), Fiche_Def\get_attr_min(), Fiche\get_bk_balance(), Customer\get_by_account(), Supplier\get_by_account(), Fiche_Def\get_by_category(), Fiche\get_by_category(), Acc_Operation\get_data(), Periode\get_date_limit(), Periode\get_exercice(), Acc_Operation\get_internal(), Anc_Operation\get_jrid(), Acc_Operation\get_jrnx_detail(), Acc_Report\get_list(), Acc_Account_Ledger\get_name(), Acc_Ledger\get_name(), Acc_Reconciliation\get_reconciled_amount(), Acc_Account_Ledger\get_row(), Fiche\get_row(), Acc_Ledger_History_Generic\get_row(), Acc_Report\get_row(), Fiche\get_row_date(), Fiche\get_row_result_deprecated(), Acc_Account_Ledger\get_row_sql_deprecated(), Acc_Ledger_History_Generic\get_rowSimple(), Acc_Account_Ledger\get_solde(), Acc_Account_Ledger\get_solde_detail(), Fiche\get_solde_detail(), Acc_Ledger\get_type(), Fiche_Def\getAttribut(), Stock\history(), html_min_page_start(), html_page_start(), isValid_deprecrated(), Acc_Ledger_Search\list_operation(), Acc_Ledger_Search\list_operation_to_reconcile(), Acc_Ledger\listing(), Acc_Bilan\load(), Acc_Ledger_Info\load(), Acc_Parm_Code\load(), Acc_Payment\load(), Anc_Balance_Simple\load(), Dossier\load(), Forecast\load(), Noalyss_User\load(), Todo_List\load(), Card_Property\load(), Acc_Ledger_Info\load_all(), Document_modele\myList(), Fiche_Def\myList(), query_to_csv(), Document_modele\Save(), Acc_Ledger_Info\search_id_internal(), Acc_Operation\seek_internal(), Document\send(), Acc_Reconciliation\show_detail(), Html_Table\sql2table(), Profile_Menu\sub_menu(), Document_modele\update(), Card_Property\update(), Anc_Operation\update_from_jrnx(), Customer\VatListing(), and Acc_Bilan\warning().
DatabaseCore::prepare | ( | $p_string, | |
$p_sql | |||
) |
wrapper for the function pg_prepare
$p_string | string name for pg_prepare function |
$p_sql | is the sql to prepare |
Definition at line 815 of file database_core.class.php.
References db.
DatabaseCore::query_to_csv | ( | $ret, | |
$aheader | |||
) |
with the handle of a successull query, echo each row into CSV and send it directly
type | $ret | handle to a query |
type | $aheader | double array, each item of the array contains a key type (num) and a key title |
Definition at line 977 of file database_core.class.php.
References $csv, $e, $i, $ret, $row, count(), fetch_array(), and num_row().
DatabaseCore::rollback | ( | ) |
rollback the current transaction
Definition at line 281 of file database_core.class.php.
References $Res, and exec_sql().
Referenced by exec_sql(), execute_script(), and upload().
DatabaseCore::search_sql_inject | ( | $p_sql | ) |
FInd if a SQL Select has a SQL stmt to inject or damage Data When a SELECT SQL string is build, this string could contain a SQL attempt to damage data, so the statement DELETE TRUNCATE ... are forbidden.
Throw an exception EXC_INVALID
Definition at line 1015 of file database_core.class.php.
References EXC_INVALID.
DatabaseCore::set_db | ( | $db | ) |
DatabaseCore::set_encoding | ( | $p_charset | ) |
Definition at line 96 of file database_core.class.php.
References db.
DatabaseCore::set_is_open | ( | $is_open | ) |
mixed | $is_open |
Definition at line 150 of file database_core.class.php.
References $is_open.
DatabaseCore::set_ret | ( | $ret | ) |
DatabaseCore::set_sql | ( | $sql | ) |
last SQL stmt executed
string | $sql |
Definition at line 166 of file database_core.class.php.
References $sql.
DatabaseCore::size | ( | $p_ret = null | ) |
return the number of rows found by the last query, or the number of rows from $p_ret
$p_ret | is the result of a query, the default value is null, in that case it is related to the last query |
Definition at line 405 of file database_core.class.php.
Referenced by Database\apply_patch(), and count().
DatabaseCore::start | ( | ) |
: start a transaction
Definition at line 263 of file database_core.class.php.
References $Res, and exec_sql().
DatabaseCore::status | ( | ) |
get the transaction status : The status can be
Definition at line 910 of file database_core.class.php.
References db.
|
static |
Definition at line 894 of file database_core.class.php.
DatabaseCore::upload | ( | $p_name | ) |
Definition at line 706 of file database_core.class.php.
References $new_name, db, echo_error(), and rollback().
Referenced by Database\save_receipt().
DatabaseCore::verify | ( | ) |
Definition at line 91 of file database_core.class.php.
DatabaseCore::$array |
Definition at line 44 of file database_core.class.php.
Referenced by get_array(), get_row(), and get_value().
|
private |
database connection
Definition at line 38 of file database_core.class.php.
|
private |
true is connected
Definition at line 42 of file database_core.class.php.
Referenced by get_is_open(), and set_is_open().
|
private |
return value
Definition at line 40 of file database_core.class.php.
Referenced by exec_sql(), execute(), fetch_all(), fetch_array(), fetch_result(), fetch_row(), get_ret(), make_list(), num_row(), query_to_csv(), Database\save_receipt(), and set_ret().
DatabaseCore::$sql |
last SQL stmt executed
Definition at line 43 of file database_core.class.php.
Referenced by Database\apply_patch(), clean_orphan_lob(), create_sequence(), execute_script(), get_sql(), make_list(), and set_sql().