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

search for in the

fbsql_list_dbs> <fbsql_hostname
Last updated: Fri, 29 Aug 2008

view this page in

fbsql_insert_id

(PHP 4 >= 4.0.6, PHP 5)

fbsql_insert_id直近の INSERT 処理により生成された ID を得る

説明

int fbsql_insert_id ([ resource $link_identifier ] )

直近の INSERT クエリにおいて、DEFAULT UNIQUE 定義されているカラムで生成された ID を返します。

注意: FrontBase SQL関数 fbsql_insert_id() の値は 直近に生成された DEFAULT UNIQUE の値を常に含み、 クエリ間でリセットすることはありません。

パラメータ

link_identifier

fbsql_connect() あるいは fbsql_pconnect() が返す FrontBase リンク ID。

指定しなかった場合は、この関数は FrontBase サーバでオープンしているリンクを探します。見つからないときは fbsql_connect() に引数を指定せずにコールしたときと同様にして作成します。

返り値

直近の INSERT クエリが生成した ID を返します。 直近のクエリが DEFAULT UNIQUE 値を生成していない場合は 0 を返します。

後のために値を保存する必要がある場合、値を生成するクエリの 直後にこの関数をコールするようにしてください。



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

fbsql_list_dbs> <fbsql_hostname
Last updated: Fri, 29 Aug 2008
 
 
show source | credits | sitemap | contact | advertising | mirror sites