mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-21 03:18:55 +00:00

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@78496 c90b9560-bf6c-de11-be94-00142212c4b1
74 lines
2.2 KiB
XML
74 lines
2.2 KiB
XML
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
<!-- $Revision: 1.2 $ -->
|
|
<!-- splitted from ./en/functions/fbsql.xml, last change in rev 1.26 -->
|
|
<refentry id="function.fbsql-create-blob">
|
|
<refnamediv>
|
|
<refname>fbsql_create_blob</refname>
|
|
<refpurpose>Create a BLOB</refpurpose>
|
|
</refnamediv>
|
|
<refsect1>
|
|
<title>Description</title>
|
|
<methodsynopsis>
|
|
<type>string</type><methodname>fbsql_create_blob</methodname>
|
|
<methodparam><type>string</type><parameter>blob_data</parameter></methodparam>
|
|
<methodparam choice="opt"><type>resource</type><parameter>
|
|
link_identifier
|
|
</parameter></methodparam>
|
|
</methodsynopsis>
|
|
<para>
|
|
Returns: A resource handle to the newly created blob.
|
|
</para>
|
|
<para>
|
|
<function>fbsql_create_blob</function> 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.
|
|
</para>
|
|
<example>
|
|
<title><function>fbsql_create_blob</function> example</title>
|
|
<programlisting role="php">
|
|
<![CDATA[
|
|
<?php
|
|
$link = fbsql_pconnect ("localhost", "_SYSTEM", "secret")
|
|
or die ("Could not connect");
|
|
$filename = "blobfile.bin";
|
|
$fp = fopen($filename, "rb");
|
|
$blobdata = fread($fp, filesize($filename));
|
|
fclose($fp);
|
|
|
|
$blobHandle = fbsql_create_blob($blobdata, $link);
|
|
|
|
$sql = "INSERT INTO BLOB_TABLE (BLOB_COLUMN) VALUES ($blobHandle);";
|
|
$rs = fbsql_query($sql, $link);
|
|
?>
|
|
]]>
|
|
</programlisting>
|
|
</example>
|
|
<para>
|
|
See also: <function>fbsql_create_clob</function>,
|
|
<function>fbsql_read_blob</function>,
|
|
<function>fbsql_read_clob</function>, and
|
|
<function>fbsql_set_lob_mode</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<!-- Keep this comment at the end of the file
|
|
Local variables:
|
|
mode: sgml
|
|
sgml-omittag:t
|
|
sgml-shorttag:t
|
|
sgml-minimize-attributes:nil
|
|
sgml-always-quote-attributes:t
|
|
sgml-indent-step:1
|
|
sgml-indent-data:t
|
|
indent-tabs-mode:nil
|
|
sgml-parent-document:nil
|
|
sgml-default-dtd-file:"../../../../manual.ced"
|
|
sgml-exposed-tags:nil
|
|
sgml-local-catalogs:nil
|
|
sgml-local-ecat-files:nil
|
|
End:
|
|
vim600: syn=xml fen fdm=syntax fdl=2 si
|
|
vim: et tw=78 syn=sgml
|
|
vi: ts=1 sw=1
|
|
-->
|