PHP: fbsql_list_fields - Manual

downloads | documentation | faq | getting help | mailing lists | reporting bugs | php.net sites | links | conferences | my php.net

search for in the

fbsql_list_tables fbsql_list_dbs

Last updated: Sat, 27 Jan 2007

view this page in

# fbsql_list_fields

(PHP 4 >= 4.0.6, PHP 5)

fbsql_list_fields -- List FrontBase result fields

## Описание

resource fbsql_list_fields ( string database_name, string table_name [, resource link_identifier] )

Retrieves information about the given table.

## Список параметров

`database_name`

  The database name.

`table_name`

  The table name.

`link_identifier`

  A FrontBase link identifier returned by fbsql_connect() or fbsql_pconnect().

  If optional and not specified, the function will try to find an open link to the FrontBase server and if no such link is found it will try to create one as if fbsql_connect() was called with no arguments

## Возвращаемые значения

Returns a result pointer which can be used with the `fbsql_field_xxx` functions, or `FALSE` on error.

## Errors/Exceptions

A string describing the error will be placed in `$phperrmsg`, and unless the function was called as `@fbsql()` then this error string will also be printed out.

## Примеры

Пример 1. fbsql_list_fields() example

`<?php
$link = fbsql_connect('localhost', 'myname', 'secret');
$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";;
}
?>`

Результатом выполнения данного примера будет что-то подобное:

    field1
    field2
    field3
    ...

## Смотрите также

fbsql_field_len()
fbsql_field_name()
fbsql_field_type()
fbsql_field_flags()

add a note User Contributed Notes
fbsql_list_fields
There are no user contributed notes for this page.
fbsql_list_tables fbsql_list_dbs

Last updated: Sat, 27 Jan 2007
show source | credits | stats | sitemap | contact | advertising | mirror sites
Copyright © 2001-2007 The PHP Group
All rights reserved.
This mirror generously provided by: Yahoo! Inc.
Last updated: Sat Mar 10 09:32:46 2007 PST