CUBRID support, thanks to Catalin Ciobanu
--HG-- extra : convert_revision : svn%3Ab267cdba-c1da-11dd-874b-8bacd04a0a74/trunk%40115
This commit is contained in:
@@ -0,0 +1,399 @@
|
|||||||
|
<?php
|
||||||
|
/*
|
||||||
|
* Description: A Cubrid implementation of the equivalent MySQL PHP API functions.
|
||||||
|
*
|
||||||
|
* Copyright (c) 2010 Cubrid.
|
||||||
|
* www.cubrid.org
|
||||||
|
*
|
||||||
|
* This program is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* This program is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with this program; if not, write to the Free Software
|
||||||
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
*
|
||||||
|
* Ver 1.2.1
|
||||||
|
* Last update: November 2010
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Global variables
|
||||||
|
$calculate_insert_id; // flag to indicate if calculate the last_insert_id
|
||||||
|
|
||||||
|
$cubrid_last_insert_id; // keeps the last_insert_id value
|
||||||
|
$cubrid_default_port; // default port used to coonect to Cubrid, if not explicitely secified
|
||||||
|
$cubrid_database; // keeps the current database name
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// resource mysql_connect ( [string server [, string username [, string password [, bool new_link [, int client_flags]]]]] )
|
||||||
|
function cubrid_mysql_connect($server, $username, $password, $database) {
|
||||||
|
// Note: In Cubrid, the database name is mandatory
|
||||||
|
// initialize globals
|
||||||
|
$GLOBALS['calculate_last_insert_id'] = true;
|
||||||
|
$GLOBALS['cubrid_last_insert_id'] = 0;
|
||||||
|
$GLOBALS['cubrid_default_port'] = 30000; // or use 33000
|
||||||
|
$GLOBALS['cubrid_database'] = "";
|
||||||
|
|
||||||
|
if (strpos($server, ":") > 0) {
|
||||||
|
list($host, $port)=explode(":", $server, 2);
|
||||||
|
} else {
|
||||||
|
$host=$server;
|
||||||
|
$port=$GLOBALS['cubrid_default_port']; // default port
|
||||||
|
}
|
||||||
|
|
||||||
|
// save database name
|
||||||
|
$GLOBALS['cubrid_database']=$database;
|
||||||
|
|
||||||
|
return cubrid_connect($host, $port, $database, $username, $password);
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// bool mysql_close ( [resource link_identifier] )
|
||||||
|
function cubrid_mysql_close($link_identifier) {
|
||||||
|
return cubrid_disconnect($link_identifier);
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
function cubrid_mysql_errno($link_identifier = '') {
|
||||||
|
// int mysql_errno ( [resource link_identifier] )
|
||||||
|
return cubrid_error_code();
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
function cubrid_mysql_error($link_identifier = '') {
|
||||||
|
// string mysql_error ( [resource link_identifier] )
|
||||||
|
return cubrid_error_msg();
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// resource mysql_query ( string query [, resource link_identifier] )
|
||||||
|
function cubrid_mysql_query_native($query, $link_identifier) {
|
||||||
|
$result=cubrid_execute($link_identifier, $query);
|
||||||
|
// Cubrid does not do commit automatically by default (auto-commit is off by default)
|
||||||
|
cubrid_commit ($link_identifier);
|
||||||
|
return $result;
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// resource mysql_query ( string query [, resource link_identifier] )
|
||||||
|
function cubrid_mysql_query($query, $link_identifier, $last_insert_id_column = '') {
|
||||||
|
$cubrid_query=trim($query); // need to trim to make sure we are handling properly the ";" terminator
|
||||||
|
|
||||||
|
if ($GLOBALS['calculate_last_insert_id']) {
|
||||||
|
// HACK - Cubrid does not support yet INSERT_ID()
|
||||||
|
// We need to alter the INSERT query to be able to get last_insert_id
|
||||||
|
if (startsWith($cubrid_query, "insert", false)) {
|
||||||
|
if ($cubrid_query[strlen($cubrid_query) - 1] == ";") { // remove the ";" last char
|
||||||
|
$cubrid_query=substr($cubrid_query, 0, strlen($cubrid_query) - 1) . " INTO :xyz;";
|
||||||
|
} else {
|
||||||
|
$cubrid_query=$cubrid_query . " INTO :xyz;";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$result=cubrid_execute($link_identifier, $cubrid_query);
|
||||||
|
|
||||||
|
if (!$result) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($GLOBALS['calculate_last_insert_id']) {
|
||||||
|
if (startsWith($cubrid_query, "insert", false)) {
|
||||||
|
// get the last_insert_id for the specified column (In Cubrid can be multiple auto_increment columns)
|
||||||
|
if (strlen($last_insert_id_column) > 0) {
|
||||||
|
$GLOBALS['cubrid_last_insert_id']=cubrid_get_value(cubrid_last_insert_id_query($last_insert_id_column),
|
||||||
|
$link_identifier);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
$GLOBALS['cubrid_last_insert_id']=0; // (re)set to 0
|
||||||
|
}
|
||||||
|
}
|
||||||
|
cubrid_commit ($link_identifier);
|
||||||
|
return $result;
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// array mysql_free_result ( resource $link_identifier )
|
||||||
|
function cubrid_mysql_free_result($link_identifier) {
|
||||||
|
return cubrid_free_result($link_identifier);
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// array mysql_fetch_row ( resource result )
|
||||||
|
function cubrid_mysql_fetch_row($result) {
|
||||||
|
return cubrid_fetch_row($result);
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// array mysql_fetch_array ( resource result [, int result_type] )
|
||||||
|
function cubrid_mysql_fetch_array($result, $result_type = 0) {
|
||||||
|
return cubrid_fetch($result, $result_type);
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// object mysql_fetch_object ( resource result )
|
||||||
|
function cubrid_mysql_fetch_object($result) {
|
||||||
|
return cubrid_fetch_object($result);
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// bool mysql_data_seek ( resource result, int row_number )
|
||||||
|
function cubrid_mysql_move_cursor($result, $offset) {
|
||||||
|
return cubrid_move_cursor($result, $offset);
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// object mysql_fetch_field ( resource result [, int field_offset] )
|
||||||
|
function cubrid_mysql_fetch_field($result) {
|
||||||
|
return cubrid_fetch_field($result);
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// int mysql_insert_id ( [resource link_identifier] )
|
||||||
|
function cubrid_mysql_insert_id($link_identifier = -1) {
|
||||||
|
return $GLOBALS['cubrid_last_insert_id'];
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// int mysql_num_rows ( resource result )
|
||||||
|
function cubrid_mysql_num_rows($resultSet) {
|
||||||
|
return cubrid_num_rows($resultSet);
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// int mysql_num_fields ( resource result )
|
||||||
|
function cubrid_mysql_num_fields($resultSet) {
|
||||||
|
return cubrid_num_cols($resultSet);
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// bool mysql_data_seek ( resource result, int row_number )
|
||||||
|
function cubrid_mysql_data_seek($result, $row_number) {
|
||||||
|
return cubrid_data_seek($result, $row_number);
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// Zero if successful. Non-zero if an error occurred.
|
||||||
|
function cubrid_mysql_commit($link_identifier) {
|
||||||
|
return cubrid_commit($link_identifier);
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// Zero if successful. Non-zero if an error occurred.
|
||||||
|
function cubrid_mysql_rollback($link_identifier) {
|
||||||
|
return cubrid_rollback($link_identifier);
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// string mysql_real_escape_string ( string unescaped_string [, resource link_identifier] )
|
||||||
|
function cubrid_mysql_real_escape_string($unescaped_string, $link_identifier = '') {
|
||||||
|
return str_replace("'", "''", $unescaped_string);
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// string mysql_result ( resource $result , int $row [, mixed $field = 0 ] )
|
||||||
|
function cubrid_mysql_result($result, $row, $field = 0) {
|
||||||
|
return cubrid_result($result, $row, $field);
|
||||||
|
}
|
||||||
|
|
||||||
|
// MySQL syntax:
|
||||||
|
// array mysql_fetch_assoc ( resource $result )
|
||||||
|
function cubrid_mysql_fetch_assoc($result) {
|
||||||
|
return cubrid_fetch_assoc($result);
|
||||||
|
}
|
||||||
|
|
||||||
|
// implements SHOW TABLES
|
||||||
|
function cubrid_SHOW_TABLES($link_identifier) {
|
||||||
|
return cubrid_mysql_query_native(get_SQL_SHOW_TABLES(), $link_identifier);
|
||||||
|
}
|
||||||
|
|
||||||
|
// implements DESCRIBE
|
||||||
|
function cubrid_DESCRIBE($table, $link_identifier) {
|
||||||
|
return cubrid_mysql_query_native(get_SQL_describeTableSQL($table), $link_identifier);
|
||||||
|
}
|
||||||
|
|
||||||
|
// implements SHOW INDEX
|
||||||
|
function cubrid_SHOW_INDEX_FROM($table, $link_identifier) {
|
||||||
|
return cubrid_mysql_query_native(get_SQL_SHOW_INDEX_FROM($table), $link_identifier);
|
||||||
|
}
|
||||||
|
|
||||||
|
// gets data type for a table
|
||||||
|
function cubrid_ColumnDataType($identifier, $table, $column) {
|
||||||
|
$id_result =cubrid_mysql_query_native(get_SQL_ColumnDataType($table, $column), $identifier);
|
||||||
|
$id_row =cubrid_fetch_row($id_result);
|
||||||
|
cubrid_free_result ($id_result);
|
||||||
|
$calculated_value=$id_row[0];
|
||||||
|
return $calculated_value;
|
||||||
|
}
|
||||||
|
|
||||||
|
// gets a single value as a query result
|
||||||
|
function cubrid_get_value($query, $link_identifier) {
|
||||||
|
$result=cubrid_execute($link_identifier, $query);
|
||||||
|
|
||||||
|
if ($result) {
|
||||||
|
$row =cubrid_fetch_row($result);
|
||||||
|
$value=$row[0];
|
||||||
|
} else {
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
return $value;
|
||||||
|
}
|
||||||
|
|
||||||
|
// returns the last_insert_id value
|
||||||
|
function cubrid_last_insert_id_query($last_insert_id_column, $cubrid_var = "xyz") {
|
||||||
|
return "SELECT :" . $cubrid_var . "." . $last_insert_id_column . " FROM db_root";
|
||||||
|
}
|
||||||
|
|
||||||
|
// returns the last_insert_id value
|
||||||
|
function cubrid_last_insert_id($last_insert_id_column, $link_identifier, $cubrid_var = "xyz") {
|
||||||
|
return cubrid_get_value(cubrid_last_insert_id_query($last_insert_id_column), $link_identifier);
|
||||||
|
}
|
||||||
|
|
||||||
|
// return the current Cubrid database name
|
||||||
|
function cubrid_current_database() {
|
||||||
|
return $GLOBALS['cubrid_database'];
|
||||||
|
}
|
||||||
|
|
||||||
|
// The following columns are returned:
|
||||||
|
// Field, Type, Null (YES,NO), Key (PRI,MUL), Default, Extra
|
||||||
|
function get_SQL_describeTableSQL($table) {
|
||||||
|
$sql="";
|
||||||
|
$sql=$sql . "SELECT a.attr_name as \"Field\"," . " ";
|
||||||
|
$sql=$sql . "a.data_type || '(' || a.prec || ',' || a.scale || ')' as \"Type\"," . " ";
|
||||||
|
$sql=$sql . "a.prec || ',' || a.scale as \"Size\"," . " ";
|
||||||
|
$sql=$sql . "a.is_nullable as \"Null\"," . " ";
|
||||||
|
$sql=$sql . "'*' as \"Key\"," . " ";
|
||||||
|
$sql=$sql . "a.default_value as \"Default\"," . " ";
|
||||||
|
$sql=$sql . "'' as \"Extra\"" . " ";
|
||||||
|
$sql=$sql . "FROM db_attribute a" . " ";
|
||||||
|
$sql=$sql . "WHERE a.class_name='" . $table . "'" . " ";
|
||||||
|
$sql=$sql . "order by a.def_order ASC";
|
||||||
|
|
||||||
|
return $sql;
|
||||||
|
}
|
||||||
|
|
||||||
|
// The column data type is returned
|
||||||
|
function get_SQL_ColumnDataType($table, $column) {
|
||||||
|
$sql="";
|
||||||
|
$sql=$sql . "SELECT a.data_type" . " ";
|
||||||
|
$sql=$sql . "FROM db_attribute a" . " ";
|
||||||
|
$sql=$sql . "WHERE a.class_name='" . $table . "'" . " ";
|
||||||
|
$sql=$sql . "AND a.attr_name='" . $column . "'" . " ";
|
||||||
|
$sql=$sql . "order by a.def_order ASC";
|
||||||
|
|
||||||
|
return $sql;
|
||||||
|
}
|
||||||
|
|
||||||
|
// The following columns are returned:
|
||||||
|
// Table,Non_unique,Key_name,Seq_in_index,Column_name,Collation,Cardinality,Sub_part,Packed,Index_type,Comment
|
||||||
|
function get_SQL_SHOW_INDEX_FROM($table) {
|
||||||
|
$query="";
|
||||||
|
$query=$query . "select distinct a.class_name as \"Table\"," . " ";
|
||||||
|
$query=$query . "DECODE(a.is_unique, 'YES', 'True') as \"Non_unique\"," . " ";
|
||||||
|
$query=$query . "a.index_name as \"Key_name\"," . " ";
|
||||||
|
$query=$query . "b.key_order as \"Seq_in_index\"," . " ";
|
||||||
|
$query=$query . "b.key_attr_name as \"Column_name\"," . " ";
|
||||||
|
$query=$query . "'' as \"Collation\"," . " ";
|
||||||
|
$query=$query . "'' as \"Cardinality\"," . " ";
|
||||||
|
$query=$query . "'' as \"Sub_part\"," . " ";
|
||||||
|
$query=$query . "'' as \"Packed\"," . " ";
|
||||||
|
$query=$query . "'' as \"Index_type\"," . " ";
|
||||||
|
$query=$query . "'' as \"Comment\"" . " ";
|
||||||
|
$query=$query . "from \"db_index\" a, \"db_index_key\" b" . " ";
|
||||||
|
$query=$query . "where a.index_name = b.index_name" . " ";
|
||||||
|
$query=$query . "and b.key_attr_name in (select attr_name from db_attribute where class_name = '" . $table . "')" . " ";
|
||||||
|
$query=$query . "and a.is_foreign_key = 'NO'" . " ";
|
||||||
|
$query=$query . "and a.class_name = '" . $table . "'" . " ";
|
||||||
|
$query=$query . "order by a.index_name, b.key_order,b.key_attr_name";
|
||||||
|
|
||||||
|
return $query;
|
||||||
|
}
|
||||||
|
|
||||||
|
// returns the list of non-system tables
|
||||||
|
function get_SQL_SHOW_TABLES($pattern = '') {
|
||||||
|
if (strlen($pattern) > 0) {
|
||||||
|
return "select class_name from db_class where class_type='CLASS' and is_system_class='NO' WHERE class_name LIKE '"
|
||||||
|
. $pattern . "' order by class_name ASC";
|
||||||
|
} else {
|
||||||
|
return "select class_name from db_class where class_type='CLASS' and is_system_class='NO' order by class_name ASC";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// gets Primary Keys information
|
||||||
|
function columnIsPK($dbl, $table, $column) {
|
||||||
|
$ret = false;
|
||||||
|
|
||||||
|
$sql = "";
|
||||||
|
$sql = $sql . "select db_index_key.key_attr_name" . " ";
|
||||||
|
$sql = $sql . "from db_index, db_index_key" . " ";
|
||||||
|
$sql = $sql . "where db_index.index_name = db_index_key.index_name" . " ";
|
||||||
|
$sql = $sql . "and db_index.class_name='" . $table . "'" . " ";
|
||||||
|
$sql = $sql . "and db_index_key.key_attr_name='" . $column . "'" . " ";
|
||||||
|
$sql = $sql . "and db_index.is_primary_key='YES'";
|
||||||
|
|
||||||
|
$tableSql = cubrid_execute($dbl, $sql);
|
||||||
|
|
||||||
|
if (@cubrid_num_rows($tableSql) > 0) {
|
||||||
|
$ret=true;
|
||||||
|
}
|
||||||
|
|
||||||
|
return $ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
// emulates DROP TABLE IF EXISTS
|
||||||
|
function DROP_TABLE_IF_EXISTS($tablename, $link_identifier) {
|
||||||
|
$id_result
|
||||||
|
=cubrid_mysql_query_native("SELECT class_name FROM db_class WHERE class_name='" . $tablename . "'",
|
||||||
|
$link_identifier);
|
||||||
|
$rows=cubrid_num_rows($id_result);
|
||||||
|
|
||||||
|
if ($rows > 0) {
|
||||||
|
cubrid_execute($link_identifier, "DROP TABLE " . $tablename);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// The following columns are returned:
|
||||||
|
// Field, Type, Null (YES,NO), Key (PRI,MUL), Default, Extra
|
||||||
|
function get_SQL_SHOW_COLUMNS($table) {
|
||||||
|
$sql="";
|
||||||
|
$sql=$sql . "SELECT a.attr_name as \"Field\"," . " ";
|
||||||
|
$sql=$sql . "a.data_type || '(' || a.prec || ',' || a.scale || ')' as \"Type\"," . " ";
|
||||||
|
$sql=$sql . "a.prec || ',' || a.scale as \"Size\"," . " ";
|
||||||
|
$sql=$sql . "a.is_nullable as \"Null\"," . " ";
|
||||||
|
$sql=$sql . "'*' as \"Key\"," . " ";
|
||||||
|
$sql=$sql . "a.default_value as \"Default\"," . " ";
|
||||||
|
$sql=$sql . "'' as \"Extra\"" . " ";
|
||||||
|
$sql=$sql . "FROM db_attribute a" . " ";
|
||||||
|
$sql=$sql . "WHERE a.class_name='" . $table . "'" . " ";
|
||||||
|
$sql=$sql . "order by a.def_order ASC";
|
||||||
|
|
||||||
|
return $sql;
|
||||||
|
}
|
||||||
|
|
||||||
|
function startsWith($haystack, $needle, $case = true) {
|
||||||
|
if ($case) {
|
||||||
|
return strpos($haystack, $needle, 0) == 0;
|
||||||
|
} else {
|
||||||
|
return stripos($haystack, $needle, 0) == 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function endsWith($haystack, $needle, $case = true) {
|
||||||
|
$expectedPosition=strlen($haystack) - strlen($needle);
|
||||||
|
|
||||||
|
if ($case) {
|
||||||
|
return strrpos($haystack, $needle, 0) == $expectedPosition;
|
||||||
|
} else {
|
||||||
|
return strripos($haystack, $needle, 0) == $expectedPosition;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
?>
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
DROP TABLE `wwwsqldesigner`;
|
||||||
|
|
||||||
|
CREATE TABLE `wwwsqldesigner` (
|
||||||
|
`keyword` varchar(30) NOT NULL,
|
||||||
|
`data` string,
|
||||||
|
`dt` timestamp,
|
||||||
|
PRIMARY KEY (`keyword`)
|
||||||
|
);
|
||||||
@@ -0,0 +1,195 @@
|
|||||||
|
<?php
|
||||||
|
require_once('cubrid_mysql_compat.php');
|
||||||
|
|
||||||
|
if (!function_exists('cubrid_connect') || !function_exists('cubrid_mysql_connect')) {
|
||||||
|
echo "Either Cubrid or the Cubrid MySQL compatibility library is not detected." . "<br />";
|
||||||
|
echo "Please check your instalation." . "<br />";
|
||||||
|
die;
|
||||||
|
}
|
||||||
|
|
||||||
|
set_time_limit(0);
|
||||||
|
|
||||||
|
function setup_saveloadlist() {
|
||||||
|
define("SERVER", "localhost:30000");
|
||||||
|
define("USER", "dba");
|
||||||
|
define("PASSWORD", "");
|
||||||
|
define("DB", "demodb");
|
||||||
|
define("TABLE", "wwwsqldesigner");
|
||||||
|
}
|
||||||
|
function setup_import() {
|
||||||
|
define("SERVER", "localhost:30000");
|
||||||
|
define("USER", "dba");
|
||||||
|
define("PASSWORD", "");
|
||||||
|
define("DB", "demodb");
|
||||||
|
}
|
||||||
|
function connect() {
|
||||||
|
$conn = cubrid_mysql_connect(SERVER, USER, PASSWORD, DB);
|
||||||
|
if (!$conn) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return $conn;
|
||||||
|
}
|
||||||
|
|
||||||
|
function import($conn) {
|
||||||
|
$xml = "";
|
||||||
|
|
||||||
|
$arr = array();
|
||||||
|
@ $datatypes = file("../../db/cubrid/datatypes.xml");
|
||||||
|
$arr[] = $datatypes[0];
|
||||||
|
$arr[] = '<sql db="cubrid">';
|
||||||
|
for ($i=1;$i<count($datatypes);$i++) {
|
||||||
|
$arr[] = $datatypes[$i];
|
||||||
|
}
|
||||||
|
|
||||||
|
$result = cubrid_mysql_query_native("select class_name from db_class WHERE class_type='CLASS' and is_system_class = 'NO' order by class_name", $conn);
|
||||||
|
if (cubrid_mysql_num_rows($result) > 0) {
|
||||||
|
while ($row = cubrid_mysql_fetch_assoc($result)) {
|
||||||
|
$table = $row["class_name"];
|
||||||
|
$xml .= '<table name="'.$table.'">';
|
||||||
|
|
||||||
|
$q = get_SQL_describeTableSQL($table);
|
||||||
|
$result2 = cubrid_mysql_query_native($q, $conn);
|
||||||
|
while ($row = cubrid_mysql_fetch_assoc($result2)) {
|
||||||
|
$name = $row["Field"];
|
||||||
|
$type = str_replace(",0)", ")", $row["Type"]);
|
||||||
|
$null = ($row["Null"] == "YES" ? "1" : "0");
|
||||||
|
$def = $row["Default"];
|
||||||
|
$ai = (preg_match("/auto_increment/i",$row["Extra"]) ? "1" : "0");
|
||||||
|
if ($def == "NULL") {
|
||||||
|
$def = "";
|
||||||
|
}
|
||||||
|
$xml .= '<row name="'.$name.'" null="'.$null.'" autoincrement="'.$ai.'">';
|
||||||
|
$xml .= '<datatype>'.strtoupper($type).'</datatype>';
|
||||||
|
$xml .= '<default>'.$def.'</default>';
|
||||||
|
|
||||||
|
/* fk constraints */
|
||||||
|
/*
|
||||||
|
$q = "SELECT
|
||||||
|
REFERENCED_TABLE_NAME AS 'table', REFERENCED_COLUMN_NAME AS 'column'
|
||||||
|
FROM KEY_COLUMN_USAGE k
|
||||||
|
LEFT JOIN TABLE_CONSTRAINTS c
|
||||||
|
ON k.CONSTRAINT_NAME = c.CONSTRAINT_NAME
|
||||||
|
WHERE CONSTRAINT_TYPE = 'FOREIGN KEY'
|
||||||
|
AND c.TABLE_SCHEMA = '".$db."' AND c.TABLE_NAME = '".$table."'
|
||||||
|
AND k.COLUMN_NAME = '".$name."'";
|
||||||
|
*/
|
||||||
|
$q = "SELECT NULL AS `table`, NULL AS `column` FROM db_root"; //no PHP support in CUBRID for FK
|
||||||
|
$result3 = cubrid_mysql_query_native($q, $conn);
|
||||||
|
|
||||||
|
while ($row = cubrid_mysql_fetch_assoc($result3)) {
|
||||||
|
$xml .= '<relation table="'.$row["table"].'" row="'.$row["column"].'" />';
|
||||||
|
}
|
||||||
|
|
||||||
|
$xml .= '</row>';
|
||||||
|
}
|
||||||
|
|
||||||
|
/* keys */
|
||||||
|
$q = get_SQL_SHOW_INDEX_FROM($table);
|
||||||
|
$result2 = cubrid_mysql_query_native($q, $conn);
|
||||||
|
$idx = array();
|
||||||
|
|
||||||
|
while ($row = cubrid_mysql_fetch_assoc($result2)) {
|
||||||
|
$name = $row["Key_name"];
|
||||||
|
if (array_key_exists($name, $idx)) {
|
||||||
|
$obj = $idx[$name];
|
||||||
|
} else {
|
||||||
|
$t = "INDEX";
|
||||||
|
|
||||||
|
if ($row["Non_unique"] == "0") {
|
||||||
|
$t = "UNIQUE";
|
||||||
|
}
|
||||||
|
|
||||||
|
if(columnIsPK($conn, $table, $row["Column_name"])) {
|
||||||
|
$t = "PRIMARY";
|
||||||
|
}
|
||||||
|
|
||||||
|
$obj = array(
|
||||||
|
"columns" => array(),
|
||||||
|
"type" => $t
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
$obj["columns"][] = $row["Column_name"];
|
||||||
|
$idx[$name] = $obj;
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach ($idx as $name=>$obj) {
|
||||||
|
$xml .= '<key name="'.$name.'" type="'.$obj["type"].'">';
|
||||||
|
for ($i=0;$i<count($obj["columns"]);$i++) {
|
||||||
|
$col = $obj["columns"][$i];
|
||||||
|
$xml .= '<part>'.$col.'</part>';
|
||||||
|
}
|
||||||
|
$xml .= '</key>';
|
||||||
|
}
|
||||||
|
$xml .= "</table>";
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
$xml = "<No tables found/>";
|
||||||
|
}
|
||||||
|
$arr[] = $xml;
|
||||||
|
$arr[] = '</sql>';
|
||||||
|
return implode("\n",$arr);
|
||||||
|
}
|
||||||
|
|
||||||
|
///////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
$a = (isset($_GET["action"]) ? $_GET["action"] : false);
|
||||||
|
switch ($a) {
|
||||||
|
case "list":
|
||||||
|
setup_saveloadlist();
|
||||||
|
$conn = connect();
|
||||||
|
$sql = "SELECT `keyword`, DATE_FORMAT(`dt`, '%d-%M-%Y %H:%i') AS dt FROM ".TABLE." ORDER BY dt DESC";
|
||||||
|
$result = cubrid_mysql_query_native($sql, $conn);
|
||||||
|
if(cubrid_mysql_num_rows($result) > 0) {
|
||||||
|
while ($row = cubrid_mysql_fetch_assoc($result)) {
|
||||||
|
echo $row["keyword"]." [".$row["dt"]."]\n";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case "save":
|
||||||
|
setup_saveloadlist();
|
||||||
|
$conn = connect();
|
||||||
|
$keyword = (isset($_GET["keyword"]) ? $_GET["keyword"] : "");
|
||||||
|
$keyword = cubrid_mysql_real_escape_string($keyword);
|
||||||
|
$data = file_get_contents("php://input");
|
||||||
|
if (get_magic_quotes_gpc() || get_magic_quotes_runtime()) {
|
||||||
|
$data = stripslashes($data);
|
||||||
|
}
|
||||||
|
$data = cubrid_mysql_real_escape_string($data);
|
||||||
|
$r = cubrid_mysql_query_native("SELECT * FROM ".TABLE." WHERE `keyword` = '".$keyword."'", $conn);
|
||||||
|
if (cubrid_mysql_num_rows($r) > 0) {
|
||||||
|
$res = cubrid_mysql_query_native("UPDATE ".TABLE." SET `data` = '".$data."', `dt`=SYS_TIMESTAMP WHERE `keyword` = '".$keyword."'", $conn);
|
||||||
|
} else {
|
||||||
|
$res = cubrid_mysql_query_native("INSERT INTO ".TABLE." (`keyword`, `data`, `dt`) VALUES ('".$keyword."', '".$data."', SYS_TIMESTAMP)", $conn);
|
||||||
|
}
|
||||||
|
if (!$res) {
|
||||||
|
header("HTTP/1.0 500 Internal Server Error");
|
||||||
|
} else {
|
||||||
|
header("HTTP/1.0 201 Created");
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case "load":
|
||||||
|
setup_saveloadlist();
|
||||||
|
$conn = connect();
|
||||||
|
$keyword = (isset($_GET["keyword"]) ? $_GET["keyword"] : "");
|
||||||
|
$keyword = cubrid_mysql_real_escape_string($keyword);
|
||||||
|
$result = cubrid_mysql_query_native("SELECT `data` FROM ".TABLE." WHERE `keyword` = '".$keyword."'", $conn);
|
||||||
|
$row = cubrid_mysql_fetch_assoc($result);
|
||||||
|
if (!$row) {
|
||||||
|
header("HTTP/1.0 404 Not Found");
|
||||||
|
} else {
|
||||||
|
header("Content-type: text/xml");
|
||||||
|
echo $row["data"];
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case "import":
|
||||||
|
setup_import();
|
||||||
|
$conn = connect();
|
||||||
|
header("Content-type: text/xml");
|
||||||
|
$txt = import($conn);
|
||||||
|
echo $txt;
|
||||||
|
break;
|
||||||
|
default: header("HTTP/1.0 501 Not Implemented");
|
||||||
|
}
|
||||||
|
|
||||||
|
?>
|
||||||
@@ -0,0 +1,44 @@
|
|||||||
|
<?xml version="1.0"?>
|
||||||
|
<datatypes db="cubrid">
|
||||||
|
<group label="Numeric" color="rgb(238,238,170)">
|
||||||
|
<type label="Short" length="0" sql="SHORT" quote="" />
|
||||||
|
<type label="Smallint" length="0" sql="SMALLINT" quote="" />
|
||||||
|
<type label="Integer" length="0" sql="INTEGER" quote="" />
|
||||||
|
<type label="Bigint" length="0" sql="BIGINT" quote="" />
|
||||||
|
|
||||||
|
<type label="Numeric / Decimal" length="1" sql="DECIMAL" quote="" />
|
||||||
|
<type label="Float / Single precision" length="0" sql="FLOAT" quote="" />
|
||||||
|
<type label="Double precision" length="0" sql="DOUBLE" quote="" />
|
||||||
|
|
||||||
|
<type label="Monetary" length="0" sql="MONETARY" re="MONETARY" quote="" />
|
||||||
|
</group>
|
||||||
|
|
||||||
|
<group label="Character" color="rgb(255,200,200)">
|
||||||
|
<type label="Char" length="1" sql="CHAR" quote="'"/>
|
||||||
|
<type label="Varchar" length="1" sql="VARCHAR" quote="'"/>
|
||||||
|
<type label="String" length="0" sql="STRING" quote="'"/>
|
||||||
|
</group>
|
||||||
|
|
||||||
|
<group label="National Character" color="rgb(255,225,200)">
|
||||||
|
<type label="Nchar" length="1" sql="NCHAR" quote="'"/>
|
||||||
|
<type label="Nchar Varying" length="1" sql="NCHAR VARYING" quote="'"/>
|
||||||
|
</group>
|
||||||
|
|
||||||
|
<group label="Date & Time" color="rgb(200,255,200)">
|
||||||
|
<type label="Date" length="0" sql="DATE" quote="'" />
|
||||||
|
<type label="Time" length="0" sql="TIME" quote="'" />
|
||||||
|
<type label="Datetime" length="0" sql="DATETIME" quote="'" />
|
||||||
|
<type label="Timestamp" length="0" sql="TIMESTAMP" quote="'" />
|
||||||
|
</group>
|
||||||
|
|
||||||
|
<group label="Collections" color="rgb(200,200,255)">
|
||||||
|
<type label="Set" length="0" sql="SET" quote="" />
|
||||||
|
<type label="Multiset" length="0" sql="MULTISET" quote="" />
|
||||||
|
<type label="List" length="0" sql="LIST" quote="" />
|
||||||
|
</group>
|
||||||
|
|
||||||
|
<group label="Bit strings" color="rgb(200,200,200)">
|
||||||
|
<type label="Bit" length="1" sql="BIT" quote=""/>
|
||||||
|
<type label="Bit Varying" length="1" sql="BIT VARYING" quote=""/>
|
||||||
|
</group>
|
||||||
|
</datatypes>
|
||||||
@@ -0,0 +1,152 @@
|
|||||||
|
<?xml version="1.0" ?>
|
||||||
|
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
|
||||||
|
<xsl:output method="text"/>
|
||||||
|
<xsl:template match="/sql">
|
||||||
|
--
|
||||||
|
-- CUBRID SQL Script
|
||||||
|
--
|
||||||
|
<!-- tables -->
|
||||||
|
<xsl:for-each select="table">
|
||||||
|
<xsl:text>
|
||||||
|
</xsl:text>
|
||||||
|
<xsl:text>-- Table `</xsl:text>
|
||||||
|
<xsl:value-of select="@name" />
|
||||||
|
<xsl:text>`</xsl:text>
|
||||||
|
<xsl:text>
|
||||||
|
</xsl:text>
|
||||||
|
<xsl:text>
|
||||||
|
</xsl:text>
|
||||||
|
|
||||||
|
<xsl:text>-- DROP TABLE `</xsl:text>
|
||||||
|
<xsl:value-of select="@name" />
|
||||||
|
<xsl:text>`;</xsl:text>
|
||||||
|
<xsl:text>
|
||||||
|
</xsl:text>
|
||||||
|
<xsl:text>
|
||||||
|
</xsl:text>
|
||||||
|
|
||||||
|
<xsl:text>CREATE TABLE `</xsl:text>
|
||||||
|
<xsl:value-of select="@name" />
|
||||||
|
<xsl:text>` (</xsl:text>
|
||||||
|
<xsl:text>
|
||||||
|
</xsl:text>
|
||||||
|
<xsl:for-each select="row">
|
||||||
|
<xsl:text> `</xsl:text>
|
||||||
|
<xsl:value-of select="@name" />
|
||||||
|
<xsl:text>` </xsl:text>
|
||||||
|
|
||||||
|
<xsl:value-of select="datatype" />
|
||||||
|
<xsl:text></xsl:text>
|
||||||
|
|
||||||
|
<xsl:if test="@null = 0">
|
||||||
|
<xsl:text> NOT NULL</xsl:text>
|
||||||
|
</xsl:if>
|
||||||
|
|
||||||
|
<xsl:if test="@autoincrement = 1">
|
||||||
|
<xsl:text> AUTO_INCREMENT</xsl:text>
|
||||||
|
</xsl:if>
|
||||||
|
|
||||||
|
<xsl:if test="default">
|
||||||
|
<xsl:text> DEFAULT </xsl:text>
|
||||||
|
<xsl:value-of select="default" />
|
||||||
|
<xsl:text></xsl:text>
|
||||||
|
</xsl:if>
|
||||||
|
|
||||||
|
<xsl:if test="not (position()=last())">
|
||||||
|
<xsl:text>,</xsl:text>
|
||||||
|
<xsl:text>
|
||||||
|
</xsl:text>
|
||||||
|
</xsl:if>
|
||||||
|
</xsl:for-each>
|
||||||
|
|
||||||
|
<!-- keys -->
|
||||||
|
<xsl:for-each select="key">
|
||||||
|
<xsl:text>,</xsl:text>
|
||||||
|
<xsl:text>
|
||||||
|
</xsl:text>
|
||||||
|
<xsl:choose>
|
||||||
|
<xsl:when test="@type = 'PRIMARY'"> PRIMARY KEY (</xsl:when>
|
||||||
|
<xsl:when test="@type = 'UNIQUE'"> UNIQUE KEY (</xsl:when>
|
||||||
|
<xsl:otherwise>KEY (</xsl:otherwise>
|
||||||
|
</xsl:choose>
|
||||||
|
|
||||||
|
<xsl:for-each select="part">
|
||||||
|
<xsl:text>`</xsl:text><xsl:value-of select="." /><xsl:text>`</xsl:text>
|
||||||
|
<xsl:if test="not (position() = last())">
|
||||||
|
<xsl:text>, </xsl:text>
|
||||||
|
</xsl:if>
|
||||||
|
</xsl:for-each>
|
||||||
|
<xsl:text>)</xsl:text>
|
||||||
|
</xsl:for-each>
|
||||||
|
<xsl:text>
|
||||||
|
</xsl:text>
|
||||||
|
<xsl:text>);</xsl:text>
|
||||||
|
<xsl:text>
|
||||||
|
</xsl:text>
|
||||||
|
|
||||||
|
</xsl:for-each>
|
||||||
|
|
||||||
|
<xsl:text>
|
||||||
|
</xsl:text>
|
||||||
|
<xsl:text>
|
||||||
|
-- Foreign Keys
|
||||||
|
</xsl:text>
|
||||||
|
<xsl:text>
|
||||||
|
</xsl:text>
|
||||||
|
|
||||||
|
<!-- fk -->
|
||||||
|
<xsl:for-each select="table">
|
||||||
|
<xsl:for-each select="row">
|
||||||
|
<xsl:for-each select="relation">
|
||||||
|
<xsl:text>ALTER TABLE `</xsl:text>
|
||||||
|
<xsl:value-of select="../../@name" />
|
||||||
|
<xsl:text>` ADD FOREIGN KEY (`</xsl:text>
|
||||||
|
<xsl:value-of select="../@name" />
|
||||||
|
<xsl:text>`) REFERENCES `</xsl:text>
|
||||||
|
<xsl:value-of select="@table" />
|
||||||
|
<xsl:text>` (`</xsl:text>
|
||||||
|
<xsl:value-of select="@row" />
|
||||||
|
<xsl:text>`);</xsl:text>
|
||||||
|
<xsl:text>
|
||||||
|
</xsl:text>
|
||||||
|
</xsl:for-each>
|
||||||
|
</xsl:for-each>
|
||||||
|
</xsl:for-each>
|
||||||
|
<xsl:text>
|
||||||
|
</xsl:text>
|
||||||
|
|
||||||
|
<xsl:text>
|
||||||
|
</xsl:text>
|
||||||
|
<xsl:text>
|
||||||
|
-- Test Data
|
||||||
|
</xsl:text>
|
||||||
|
<xsl:text>
|
||||||
|
</xsl:text>
|
||||||
|
|
||||||
|
<xsl:for-each select="table">
|
||||||
|
<xsl:text>-- INSERT INTO `</xsl:text><xsl:value-of select="@name" />
|
||||||
|
<xsl:text>` (</xsl:text>
|
||||||
|
<xsl:for-each select="row">
|
||||||
|
<xsl:text>`</xsl:text>
|
||||||
|
<xsl:value-of select="@name" />
|
||||||
|
<xsl:text>`</xsl:text>
|
||||||
|
<xsl:if test="not (position()=last())">
|
||||||
|
<xsl:text>,</xsl:text>
|
||||||
|
</xsl:if>
|
||||||
|
</xsl:for-each>
|
||||||
|
<xsl:text>) VALUES
|
||||||
|
-- (</xsl:text>
|
||||||
|
<xsl:for-each select="row">
|
||||||
|
<xsl:text>''</xsl:text>
|
||||||
|
<xsl:if test="not (position()=last())">
|
||||||
|
<xsl:text>,</xsl:text>
|
||||||
|
</xsl:if>
|
||||||
|
</xsl:for-each>
|
||||||
|
<xsl:text>);</xsl:text>
|
||||||
|
<xsl:text>
|
||||||
|
</xsl:text>
|
||||||
|
</xsl:for-each>
|
||||||
|
|
||||||
|
</xsl:template>
|
||||||
|
</xsl:stylesheet>
|
||||||
|
|
||||||
+3
-3
@@ -1,11 +1,11 @@
|
|||||||
var CONFIG = {
|
var CONFIG = {
|
||||||
AVAILABLE_DBS: ["mysql", "sqlite", "web2py", "mssql", "postgresql", "oracle", "sqlalchemy", "vfp9"],
|
AVAILABLE_DBS: ["mysql", "sqlite", "web2py", "mssql", "postgresql", "oracle", "sqlalchemy", "vfp9", "cubrid"],
|
||||||
DEFAULT_DB: "mysql",
|
DEFAULT_DB: "mysql",
|
||||||
|
|
||||||
AVAILABLE_LOCALES: ["cs", "de", "el", "en", "eo", "es", "fr", "hu", "it", "ja", "pl", "pt_BR", "ru", "zh"],
|
AVAILABLE_LOCALES: ["cs", "de", "el", "en", "eo", "es", "fr", "hu", "it", "ja", "pl", "pt_BR", "ro", "ru", "zh"],
|
||||||
DEFAULT_LOCALE: "en",
|
DEFAULT_LOCALE: "en",
|
||||||
|
|
||||||
AVAILABLE_BACKENDS: ["php-mysql", "php-blank", "php-file", "php-sqlite", "php-mysql+file", "php-postgresql", "php-pdo", "perl-file"],
|
AVAILABLE_BACKENDS: ["php-mysql", "php-blank", "php-file", "php-sqlite", "php-mysql+file", "php-postgresql", "php-pdo", "perl-file", "php-cubrid"],
|
||||||
DEFAULT_BACKEND: ["php-mysql"],
|
DEFAULT_BACKEND: ["php-mysql"],
|
||||||
|
|
||||||
RELATION_THICKNESS: 2,
|
RELATION_THICKNESS: 2,
|
||||||
|
|||||||
@@ -0,0 +1,97 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<locale>
|
||||||
|
<!-- table management -->
|
||||||
|
<string name="addtable">Adauga tabela</string>
|
||||||
|
<string name="edittable">Editeaza tabela</string>
|
||||||
|
<string name="removetable">Sterge tabela</string>
|
||||||
|
<string name="removetables">Sterge tabelele</string>
|
||||||
|
<string name="aligntables">Aliniaza tabelele</string>
|
||||||
|
<string name="cleartables">Sterge tabelele</string>
|
||||||
|
<string name="confirmall">Sterge toate tabelele</string>
|
||||||
|
<string name="newtable">(nume tabela)</string>
|
||||||
|
<string name="addpending">plaseaza tabela</string>
|
||||||
|
<string name="tablenamelabel">Nume</string>
|
||||||
|
<string name="tablecommentlabel">Comentariu</string>
|
||||||
|
|
||||||
|
<!-- row management -->
|
||||||
|
<string name="addrow">Adauga coloana</string>
|
||||||
|
<string name="editrow">Editeaza coloana</string>
|
||||||
|
<string name="removerow">Sterge coloana</string>
|
||||||
|
<string name="uprow">Sus</string>
|
||||||
|
<string name="downrow">Jos</string>
|
||||||
|
<string name="newrow">coloana noua</string>
|
||||||
|
<string name="foreigncreate">Creaza FK</string>
|
||||||
|
<string name="foreignpending">alege destinatie</string>
|
||||||
|
<string name="foreignconnect">Conexiune FK</string>
|
||||||
|
<string name="foreignconnectpending">alege destinatie</string>
|
||||||
|
<string name="foreigndisconnect">Sterge FK</string>
|
||||||
|
<string name="confirmtable">Sterge tabela</string>
|
||||||
|
<string name="confirmrow">Sterge coloana</string>
|
||||||
|
|
||||||
|
<!-- editare rand -->
|
||||||
|
<string name="name">Nume</string>
|
||||||
|
<string name="type">Tip</string>
|
||||||
|
<string name="size">Dimensiune</string>
|
||||||
|
<string name="def">Valoare default</string>
|
||||||
|
<string name="notnull">NOT NULL</string>
|
||||||
|
<string name="null">NULL</string>
|
||||||
|
<string name="ai">Auto increment</string>
|
||||||
|
<string name="comment">Editare comentariu</string>
|
||||||
|
<string name="commenttext">Introduceti comentariul pentru aceasta coloana:</string>
|
||||||
|
|
||||||
|
<!-- windows & options -->
|
||||||
|
<string name="windowok">OK</string>
|
||||||
|
<string name="windowcancel">Anuleaza</string>
|
||||||
|
<string name="throbber">Asteptati va rog...</string>
|
||||||
|
<string name="options">Optiuni</string>
|
||||||
|
<string name="language">Limbaj</string>
|
||||||
|
<string name="db">Baza de date pentru design</string>
|
||||||
|
<string name="optionsnotice">Anumite optiuni devin active numai dupa o reincarcare completa a paginii. Cookies trebuie sa fie activate pentru browser.</string>
|
||||||
|
<string name="snap">Distanta automata intre tabele</string>
|
||||||
|
<string name="optionsnapnotice">In pixeli, 0 = dezactiveaza asezarea automata</string>
|
||||||
|
<string name="pattern">Modelul pentru nume de Foreign Keys</string>
|
||||||
|
<string name="optionpatternnotice">%T = Tabela primara, %R = Primary key, %t = Tabela cu Foreign key</string>
|
||||||
|
<string name="hide">Ascunde conexiunile la mutarea tabelei?</string>
|
||||||
|
<string name="vector">Deseneaza folosind "smooth connectors" (daca browserul suporta)?</string>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- keys -->
|
||||||
|
<string name="tablekeys">Keys / Indexes</string>
|
||||||
|
<string name="keyslistlabel">Keys / Indexes in tabela "%s"</string>
|
||||||
|
<string name="keytypelabel">Tip:</string>
|
||||||
|
<string name="keynamelabel">Nume:</string>
|
||||||
|
<string name="keyfieldslabel">Campuri selectate</string>
|
||||||
|
<string name="keyavaillabel">Campuri disponibile</string>
|
||||||
|
<string name="keyedit">Editeaza</string>
|
||||||
|
<string name="keyadd">Adauga</string>
|
||||||
|
<string name="keyremove">Sterge</string>
|
||||||
|
|
||||||
|
<!-- io -->
|
||||||
|
<string name="saveload">Salveaza / Incarca</string>
|
||||||
|
<string name="empty">Introduceti codul XML si re-incercati.</string>
|
||||||
|
<string name="client">Client</string>
|
||||||
|
<string name="server">Server</string>
|
||||||
|
<string name="output">Input / Output</string>
|
||||||
|
<string name="clientsave">Genereaza XML</string>
|
||||||
|
<string name="clientload">Incarca din XML</string>
|
||||||
|
<string name="clientsql">Genereaza SQL</string>
|
||||||
|
<string name="backendlabel">Server backend:</string>
|
||||||
|
<string name="serversave">Salveaza</string>
|
||||||
|
<string name="serverload">Incarca</string>
|
||||||
|
<string name="serverlist">Lista de salvari</string>
|
||||||
|
<string name="serverimport">Import tabele din baza de date</string>
|
||||||
|
<string name="serverloadprompt">Introduceti numele sub care a fost salvat design-ul:</string>
|
||||||
|
<string name="serversaveprompt">Introduceti numele sub care va fi salvat design-ul:</string>
|
||||||
|
<string name="serverimportprompt">Introduceti numele bazei de date care va fi importata:</string>
|
||||||
|
<string name="httpresponse">Server response</string>
|
||||||
|
<string name="http201">Salvare efectuata</string>
|
||||||
|
<string name="http404">Not Found</string>
|
||||||
|
<string name="http500">Internal Server Error</string>
|
||||||
|
<string name="http501">Not Implemented</string>
|
||||||
|
<string name="http503">Service Unavailable</string>
|
||||||
|
|
||||||
|
<!-- diverse -->
|
||||||
|
<string name="xmlerror">Eroare XML</string>
|
||||||
|
<string name="docs">Documentatie</string>
|
||||||
|
|
||||||
|
</locale>
|
||||||
Reference in New Issue
Block a user