From ba19739f4f2bb666703d2afe9acd28abeb6ba770 Mon Sep 17 00:00:00 2001 From: Egon Schmid Date: Wed, 17 Oct 2001 20:50:36 +0000 Subject: [PATCH] White space, punctuation and some typos. git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@60114 c90b9560-bf6c-de11-be94-00142212c4b1 --- functions/fbsql.xml | 418 +++++++++++++++++++++++--------------------- 1 file changed, 222 insertions(+), 196 deletions(-) diff --git a/functions/fbsql.xml b/functions/fbsql.xml index 57151e0574..6912c82b7b 100644 --- a/functions/fbsql.xml +++ b/functions/fbsql.xml @@ -1,21 +1,21 @@ - + - FrontBase functions + FrontBase Functions FrontBase These functions allow you to access FrontBase database servers. In - order to have these functions available, you must compile php - with fbsql support by using the - option. If you - use this option without specifying the path to fbsql, php will - search for the fbsql client libraries in the default installation - location for the platform. Users who installed FrontBase in - a non standard directory should always specify the path to fbsql: - . - This will force php to use the client libraries installed by - FrontBase, avoiding any conflicts. + order to have these functions available, you must compile php with + fbsql support by using the option. If you use this + option without specifying the path to fbsql, php will search for + the fbsql client libraries in the default installation location + for the platform. Users who installed FrontBase in a non standard + directory should always specify the path to fbsql: . This will + force php to use the client libraries installed by FrontBase, + avoiding any conflicts. More information about FrontBase can be found at fbsql_affected_rows - Get number of affected rows in previous FrontBase - operation + + Get number of affected rows in previous FrontBase operation + Description @@ -63,17 +64,17 @@ - If the last query was a DELETE query with no WHERE clause, all - of the records will have been deleted from the table but this + If the last query was a DELETE query with no WHERE clause, all of + the records will have been deleted from the table but this function will return zero. - When using UPDATE, FrontBase will not update columns where the new - value is the same as the old value. This creates the possiblity - that fbsql_affected_rows may not actually - equal the number of rows matched, only the number of rows that - were literally affected by the query. + When using UPDATE, FrontBase will not update columns where the + new value is the same as the old value. This creates the + possiblity that fbsql_affected_rows may not + actually equal the number of rows matched, only the number of + rows that were literally affected by the query. @@ -112,7 +113,7 @@ With OnOff set to &true; each statement will be commited automatically, if no errors was found. With OnOff set to &false; the user must commit or rollback - the transaction unsing either fbsql_commit or + the transaction using either fbsql_commit or fbsql_rollback. See also: @@ -150,11 +151,11 @@ fbsql_change_user changes the logged in user - of the current active connection, or the connection given by the - optional parameter link_identifier. If a database is - specified, this will default or current database after the user - has been changed. If the new user and password authorization fails, - the current connected user stays active. + of the current active connection, or the connection given by the + optional parameter link_identifier. If a database is specified, + this will default or current database after the user has been + changed. If the new user and password authorization fails, the + current connected user stays active. @@ -179,10 +180,11 @@ Returns: &true; on success, &false; on error. - fbsql_close closes the connection to - the FrontBase server that's associated with the specified link - identifier. If link_identifier isn't - specified, the last opened link is used. + + fbsql_close closes the connection to the + FrontBase server that's associated with the specified link + identifier. If link_identifier isn't + specified, the last opened link is used. Using fbsql_close isn't usually necessary, @@ -228,10 +230,10 @@ Returns: &true; on success, &false; on failure. - fbsql_commit ends the current transaction - by writing all insertsm updates and deletes to the disk and unlucking - all row and table locks held by the transaction. - This command is only needed if autocommit is set to false. + fbsql_commit ends the current transaction by + writing all insertsm updates and deletes to the disk and + unlucking all row and table locks held by the transaction. This + command is only needed if autocommit is set to false. See also: fbsql_autocommit and @@ -269,14 +271,14 @@ - Returns a positive FrontBase link identifier on success, or an error - message on failure. + Returns a positive FrontBase link identifier on success, or an + error message on failure. - fbsql_connect establishes a connection - to a FrontBase server. The following defaults are assumed for - missing optional parameters: hostname = - '&null;', username = '_SYSTEM' and + fbsql_connect establishes a connection to a + FrontBase server. The following defaults are assumed for missing + optional parameters: hostname = '&null;', + username = '_SYSTEM' and password = empty password. @@ -376,9 +378,9 @@ Returns: A resource handle to the newly created blob. - fbsql_create_blob creates a blob from blob_data. - The returned resource handle can be used with insert and update commands - to store the blob in the database. + fbsql_create_blob creates a blob from + blob_data. The returned resource handle can be used with insert + and update commands to store the blob in the database. <function>fbsql_create_blob</function> example @@ -398,11 +400,11 @@ ?> - See also: - fbsql_create_clob, - fbsql_read_blob, - fbsql_read_clob, - fbsql_set_lob_mode + + See also: fbsql_create_clob, + fbsql_read_blob, + fbsql_read_clob, and + fbsql_set_lob_mode. @@ -429,9 +431,9 @@ Returns: A resource handle to the newly created CLOB. - fbsql_create_clob creates a clob from clob_data. - The returned resource handle can be used with insert and update commands - to store the clob in the database. + fbsql_create_clob creates a clob from + clob_data. The returned resource handle can be used with insert + and update commands to store the clob in the database. <function>fbsql_create_clob</function> example @@ -451,11 +453,11 @@ ?> - See also: - fbsql_create_blob, - fbsql_read_blob, - fbsql_read_clob, - fbsql_set_lob_mode + + See also: fbsql_create_blob, + fbsql_read_blob, + fbsql_read_clob, and + fbsql_set_lob_mode. @@ -463,15 +465,20 @@ fbsql_database_password - Sets or retreives the password for a FrontBase database + + Sets or retreives the password for a FrontBase database + Description - string fbsql_database_password - resource link_identifier - string + string + fbsql_database_password + + resource + link_identifier + string database_password @@ -479,22 +486,22 @@ - Returns: The database password for the database represented by the link - identifier. + Returns: The database password for the database represented by + the link identifier. fbsql_database_password sets and retreives - the database password for the current database. - if the second optional parameter is given the function sets the - database password for the database on the server that's associated - with the specified link identifier. If no link identifier is specified, - the last opened link is assumed. If no link is open, the function will - try to establish a link as if fbsql_connect was - called, and use it. + the database password for the current database. if the second + optional parameter is given the function sets the database + password for the database on the server that's associated with + the specified link identifier. If no link identifier is + specified, the last opened link is assumed. If no link is open, + the function will try to establish a link as if + fbsql_connect was called, and use it. - See also: - fbsql_connect and - fbsql_pconnect + + See also: fbsql_connect and + fbsql_pconnect. @@ -509,7 +516,9 @@ bool fbsql_data_seek - resource result_identifier + resource + result_identifier + int row_number @@ -518,14 +527,14 @@ fbsql_data_seek moves the internal row - pointer of the FrontBase result associated with the specified result - identifier to point to the specified row number. The next call - to fbsql_fetch_row would return that row. + pointer of the FrontBase result associated with the specified + result identifier to point to the specified row number. The next + call to fbsql_fetch_row would return that + row. Row_number starts at 0. - <function>fbsql_data_seek</function> example @@ -581,15 +590,15 @@ - Returns: A positive FrontBase result identifier to the query result, - or &false; on error. + Returns: A positive FrontBase result identifier to the query + result, or &false; on error. fbsql_db_query selects a database and executes a query on it. If the optional link identifier isn't specified, the function will try to find an open link to the - FrontBase server and if no such link is found it'll try to create one - as if fbsql_connect was called with no + FrontBase server and if no such link is found it'll try to create + one as if fbsql_connect was called with no arguments @@ -601,7 +610,7 @@ fbsql_db_status - Get the status for a given database. + Get the status for a given database Description @@ -620,9 +629,10 @@ Returns: An integer value with the current status. - fbsql_db_status requests the current - status of the database specified by database_name. - if the link_identifier is omitted the default + fbsql_db_status requests the current status + of the database specified by + database_name. If the + link_identifier is omitted the default link_identifier will be used. @@ -632,8 +642,8 @@ &false; - The exec handler for the host was invalid. This error will ocour when the link_identifier connects directly to - a database by using a port number. FBExec can be available on the - server but no connection has been made for it. + a database by using a port number. FBExec can be available on + the server but no connection has been made for it. @@ -671,9 +681,9 @@ - See also: - fbsql_start_db and - fbsql_stop_db + + See also: fbsql_start_db and + fbsql_stop_db. @@ -710,8 +720,10 @@ fbsql_errno - Returns the numerical value of the error message from previous - FrontBase operation + + Returns the numerical value of the error message from previous + FrontBase operation + Description @@ -730,14 +742,13 @@ 0 (zero) if no error occurred. - Errors coming back from the fbsql database backend dont - issue warnings. Instead, use fbsql_errno to + Errors coming back from the fbsql database backend dont issue + warnings. Instead, use fbsql_errno to retrieve the error code. Note that this function only returns the error code from the most recently executed fbsql function (not including fbsql_error and - fbsql_errno), so if you want to use it, - make sure you check the value before calling another fbsql - function. + fbsql_errno), so if you want to use it, make + sure you check the value before calling another fbsql function. <?php @@ -752,8 +763,8 @@ echo fbsql_errno().": ".fbsql_error()."<BR>"; - See also: fbsql_error, - fbsql_warnings + See also: fbsql_error and + fbsql_warnings. @@ -761,8 +772,10 @@ echo fbsql_errno().": ".fbsql_error()."<BR>"; fbsql_error - Returns the text of the error message from previous - FrontBase operation + + Returns the text of the error message from previous FrontBase + operation + Description @@ -781,8 +794,8 @@ echo fbsql_errno().": ".fbsql_error()."<BR>"; '' (the empty string) if no error occurred. - Errors coming back from the fbsql database backend dont - issue warnings. Instead, use fbsql_error to + Errors coming back from the fbsql database backend dont issue + warnings. Instead, use fbsql_error to retrieve the error text. Note that this function only returns the error text from the most recently executed fbsql function (not including fbsql_error and @@ -802,8 +815,8 @@ echo fbsql_errno().": ".fbsql_error()."<BR>"; - See also: fbsql_errno, - fbsql_warnings + See also: fbsql_errno and + fbsql_warnings. @@ -812,7 +825,8 @@ echo fbsql_errno().": ".fbsql_error()."<BR>"; fbsql_fetch_array - Fetch a result row as an associative array, a numeric array, or both. + Fetch a result row as an associative array, a numeric array, or + both @@ -830,7 +844,8 @@ echo fbsql_errno().": ".fbsql_error()."<BR>"; Returns an array that corresponds to the fetched row, or &false; - if there are no more rows. + if there are no more rows. + fbsql_fetch_array is an extended version of fbsql_fetch_row. In addition to storing the @@ -862,7 +877,8 @@ select t1.f1 as foo t2.f1 as bar from t1, t2 For further details, see also - fbsql_fetch_row and fbsql_fetch_assoc. + fbsql_fetch_row and + fbsql_fetch_assoc. <function>fbsql_fetch_array</function> example @@ -923,7 +939,8 @@ fbsql_free_result ($result); For further details, see also - fbsql_fetch_row and fbsql_fetch_array. + fbsql_fetch_row and + fbsql_fetch_array. <function>fbsql_fetch_assoc</function> example @@ -1165,7 +1182,7 @@ fbsql_free_result ($result); See also: fbsql_fetch_array, fbsql_fetch_object, fbsql_data_seek, - fbsql_fetch_lengths and + fbsql_fetch_lengths, and fbsql_result. @@ -1430,8 +1447,8 @@ fbsql_close(); fbsql_insert_id returns the ID generated for - an column defined as DEFAULT UNIQUE by the previous INSERT query using the - given link_identifier. If + an column defined as DEFAULT UNIQUE by the previous INSERT query + using the given link_identifier. If link_identifier isn't specified, the last opened link is assumed. @@ -1447,7 +1464,7 @@ fbsql_close(); LAST_INSERT_ID() always contains the most recently generated DEFAULT UNIQUE value, and is not reset between queries. - + @@ -1485,7 +1502,7 @@ $link = fbsql_connect('localhost', 'myname', 'secret'); $db_list = fbsql_list_dbs($link); while ($row = fbsql_fetch_object($db_list)) { - echo $row->Database . "\n"; + echo $row->Database . "\n"; } @@ -1535,7 +1552,7 @@ database3 the table name. A result pointer is returned which can be used with fbsql_field_flags, fbsql_field_len, - fbsql_field_name and + fbsql_field_name, and fbsql_field_type. @@ -1555,7 +1572,7 @@ $fields = fbsql_list_fields("database1", "table1", $link); $columns = fbsql_num_fields($fields); for ($i = 0; $i < $columns; $i++) { - echo fbsql_field_name($fields, $i) . "\n";; + echo fbsql_field_name($fields, $i) . "\n";; } @@ -1605,7 +1622,9 @@ field3 fbsql_next_result - Move the internal result pointer to the next result + + Move the internal result pointer to the next result + Description @@ -1618,13 +1637,14 @@ field3 - When sending more than one SQL statement to the server or executing a stored procedure - with multiple results will cause the server to return multiple result sets. - This function will test for additional results available form the server. if an - additional result set exists it will free the existing result set and prepare to - fetch the wors from the new result set. - The function will return &true; if an additional result set was - available or &false; othervise. + When sending more than one SQL statement to the server or + executing a stored procedure with multiple results will cause the + server to return multiple result sets. This function will test + for additional results available form the server. If an + additional result set exists it will free the existing result set + and prepare to fetch the words from the new result set. The + function will return &true; if an additional result set was + available or &false; otherwise. <function>fbsql_next_result</function> example @@ -1667,8 +1687,9 @@ field3 See also: fbsql_db_query, fbsql_query, - fbsql_fetch_field, - fbsql_num_rows. + fbsql_fetch_field, and + fbsql_num_rows. + @@ -1687,8 +1708,8 @@ field3 fbsql_num_rows returns the number of rows in - a result set. This command is only valid for SELECT statements. - To retrieve the number of rows returned from a INSERT, UPDATE or + a result set. This command is only valid for SELECT statements. + To retrieve the number of rows returned from a INSERT, UPDATE or DELETE query, use fbsql_affected_rows. <function>fbsql_num_rows</function> example @@ -1708,10 +1729,9 @@ echo "$num_rows Rows\n"; - See also: - fbsql_affected_rows, - fbsql_connect, - fbsql_select_db and + See also: fbsql_affected_rows, + fbsql_connect, + fbsql_select_db, and fbsql_query. @@ -1741,8 +1761,8 @@ echo "$num_rows Rows\n"; - Returns: A positive FrontBase persistent link identifier on success, - or &false; on error. + Returns: A positive FrontBase persistent link identifier on + success, or &false; on error. fbsql_pconnect establishes a connection @@ -1756,7 +1776,8 @@ echo "$num_rows Rows\n"; fbsql_connect with two major differences. - To set Frontbase server port number, use fbsql_select_db. + To set Frontbase server port number, use + fbsql_select_db. First, when connecting, the function would first try to find a @@ -1842,9 +1863,9 @@ $result = fbsql_query ("SELECT my_col FROM my_tbl") - fbsql_query will also fail and return &false; - if you don't have permission to access the table(s) referenced by - the query. + fbsql_query will also fail and return + &false; if you don't have permission to access the table(s) + referenced by the query. Assuming the query succeeds, you can call @@ -1868,7 +1889,7 @@ $result = fbsql_query ("SELECT my_col FROM my_tbl") fbsql_db_query, fbsql_free_result, fbsql_result, - fbsql_select_db and + fbsql_select_db, and fbsql_connect. @@ -1896,13 +1917,14 @@ $result = fbsql_query ("SELECT my_col FROM my_tbl") Returns: A string containing the BLOB specified by blob_handle. - fbsql_read_blob reads BLOB data from the database. - If a select statement contains BLOB and/or BLOB columns FrontBase - will return the data directly when data is fetched. This default - behavior can be changed with fbsql_set_lob_mode so - the fetch functions will return handles to BLOB and CLOB data. - If a handle is fetched a user must call fbsql_read_blob - to get the actual BLOB data from the database. + fbsql_read_blob reads BLOB data from the + database. If a select statement contains BLOB and/or BLOB + columns FrontBase will return the data directly when data is + fetched. This default behavior can be changed with + fbsql_set_lob_mode so the fetch functions + will return handles to BLOB and CLOB data. If a handle is + fetched a user must call fbsql_read_blob to + get the actual BLOB data from the database. <function>fbsql_read_blob</function> example @@ -1926,11 +1948,11 @@ $result = fbsql_query ("SELECT my_col FROM my_tbl") ?> - See also: - fbsql_create_blob, - fbsql_read_blob, - fbsql_read_clob, - fbsql_set_lob_mode + + See also: fbsql_create_blob, + fbsql_read_blob, + fbsql_read_clob, and + fbsql_set_lob_mode. @@ -1957,13 +1979,14 @@ $result = fbsql_query ("SELECT my_col FROM my_tbl") Returns: A string containing the CLOB specified by clob_handle. - fbsql_read_clob reads CLOB data from the database. - If a select statement contains BLOB and/or CLOB columns FrontBase - will return the data directly when data is fetched. This default - behavior can be changed with fbsql_set_lob_mode so - the fetch functions will return handles to BLOB and CLOB data. - If a handle is fetched a user must call fbsql_read_clob - to get the actual CLOB data from the database. + fbsql_read_clob reads CLOB data from the + database. If a select statement contains BLOB and/or CLOB + columns FrontBase will return the data directly when data is + fetched. This default behavior can be changed with + fbsql_set_lob_mode so the fetch functions + will return handles to BLOB and CLOB data. If a handle is + fetched a user must call fbsql_read_clob to + get the actual CLOB data from the database. <function>fbsql_read_clob</function> example @@ -1987,11 +2010,11 @@ $result = fbsql_query ("SELECT my_col FROM my_tbl") ?> - See also: - fbsql_create_blob, - fbsql_read_blob, - fbsql_read_clob, - fbsql_set_lob_mode + + See also: fbsql_create_blob, + fbsql_read_blob, + fbsql_read_clob, and + fbsql_set_lob_mode. @@ -2039,7 +2062,7 @@ $result = fbsql_query ("SELECT my_col FROM my_tbl") Recommended high-performance alternatives: fbsql_fetch_row, - fbsql_fetch_array and + fbsql_fetch_array, and fbsql_fetch_object. @@ -2080,7 +2103,9 @@ $result = fbsql_query ("SELECT my_col FROM my_tbl") fbsql_set_lob_mode - Set the LOB retreive mode for a FrontBase result set + + Set the LOB retreive mode for a FrontBase result set + Description @@ -2096,30 +2121,31 @@ $result = fbsql_query ("SELECT my_col FROM my_tbl") fbsql_set_lob_mode sets the mode for - retreiving LOB data from the database. When BLOB and CLOB data - is stored in FrontBase it can be stored direct or indirect. - Direct stored LOB data will allways be fetched no matter the setting - of the lob mode. If the LOB data is less than 512 bytes it will allways - be stored directly. + retreiving LOB data from the database. When BLOB and CLOB data is + stored in FrontBase it can be stored direct or indirect. Direct + stored LOB data will allways be fetched no matter the setting of + the lob mode. If the LOB data is less than 512 bytes it will + allways be stored directly. - FBSQL_LOB_DIRECT - LOB data is retreived directly. When data is - fetched from the database with fbsql_fetch_row, - and other fetch functions, all CLOB and BLOB columns will be returned - as ordinary coluimns. - This is the default value on a new FrontBase resutl. + FBSQL_LOB_DIRECT - LOB data is retreived directly. When data + is fetched from the database with + fbsql_fetch_row, and other fetch + functions, all CLOB and BLOB columns will be returned as + ordinary columns. This is the default value on a new + FrontBase result. - FBSQL_LOB_HANDLE - LOB data is retreived as handles to the data. - When data is fetched from the database with fbsql_fetch_row - , and other fetch functions, LOB data will be returned as - a handle to the data if the data is stored indirect or the data if it - is stored direct. - If a handle is returned it will be a 27 byte string formated as - "@'000000000000000000000000'". + FBSQL_LOB_HANDLE - LOB data is retreived as handles to the + data. When data is fetched from the database with + fbsql_fetch_row , and other fetch + functions, LOB data will be returned as a handle to the data + if the data is stored indirect or the data if it is stored + direct. If a handle is returned it will be a 27 byte string + formated as "@'000000000000000000000000'". @@ -2127,8 +2153,8 @@ $result = fbsql_query ("SELECT my_col FROM my_tbl") See also: fbsql_create_blob, fbsql_create_clob, - fbsql_read_blob and - fbsql_read_clob + fbsql_read_blob, and + fbsql_read_clob. @@ -2164,11 +2190,11 @@ $result = fbsql_query ("SELECT my_col FROM my_tbl") The client contacts FBExec to obtain the port number to use for - the connection to the database. if the database name is a number + the connection to the database. If the database name is a number the system will use that as a port number and it will not ask - FBExec for the port number. - The FrontBase server can be stared as - FRontBase -FBExec=No -port=<port number> <database name>. + FBExec for the port number. The FrontBase server can be stared + as FRontBase -FBExec=No -port=<port number> <database + name>. Every subsequent call to fbsql_query will be @@ -2176,7 +2202,7 @@ $result = fbsql_query ("SELECT my_col FROM my_tbl") See also: fbsql_connect, - fbsql_pconnect and + fbsql_pconnect, and fbsql_query. @@ -2206,9 +2232,9 @@ $result = fbsql_query ("SELECT my_col FROM my_tbl") fbsql_start_db - See also: - fbsql_db_status and - fbsql_stop_db + + See also: fbsql_db_status and + fbsql_stop_db. @@ -2237,9 +2263,9 @@ $result = fbsql_query ("SELECT my_col FROM my_tbl") fbsql_stop_db - See also: - fbsql_db_status and - fbsql_start_db + + See also: fbsql_db_status and + fbsql_start_db.