PHP mysqli set_local_infile_handler () وظيفة
التعريف والاستخدام
تعين الدالة set_local_infile_handler () / mysqli_set_local_infile_handler () وظيفة رد اتصال لأمر LOAD DATA LOCAL INFILE.
تتمثل مهام وظائف رد الاتصال في قراءة المدخلات من الملف المحدد في LOAD DATA LOCAL INFILE ، وإعادة تنسيقه إلى التنسيق الذي يفهمه LOAD DATA INFILE.
يجب أن تتطابق البيانات التي تم إرجاعها مع التنسيق المحدد في LOAD DATA.
بناء الجملة
النمط الموجه للكائن:
$mysqli ->
set_local_infile_handler(read_file)
الأسلوب الإجرائي:
mysqli_set_local_infile_handler(read_file)
قيمه المعامل
Parameter | Description |
---|---|
connection | Required. Specifies the MySQL connection to use |
read_func | Required. Specifies a callback function or objext that can take the
following params: stream - A PHP stream associated with the SQL commands INFILE &buffer - A string buffer to store the rewritten input into buflen - The maximum number of characters to be stored in the buffer &erromsg - If an error occurs you can store an error message in here |
تفاصيل تقنية
قيمة الإرجاع: | صواب في النجاح. خطأ في الفشل |
---|---|
إصدار PHP: | 5+ |
❮ PHP مرجع MySQLi