oci

What is wrong with the installation of php oracle client oci8

血红的双手。 提交于 2019-12-11 05:14:08
问题 I tried all the procedures to install the PHP Oracle client. 1) I installed the Client version 8 and 32 bits. 2) I uncommented oci in php.ini 3) Restarted Wamp: 4) Not sure if really installed but I got the references in php.ini: 5) But still cannot connect: Tyhanks for any help EDIT Found these errors in php log: [16-Apr-2018 14:35:03 UTC] PHP Warning: PHP Startup: Unable to load dynamic library 'c:/wamp/bin/php/php5.5.12/ext/php_oci8.dll' - %1 is not a valid Win32 application. in Unknown on

How can I prevent SQL injections in the PHP oci extension?

拟墨画扇 提交于 2019-12-11 02:51:47
问题 I see a lot of questions on here regarding MySQL, but what about when using OCI? Is the simplest method to create a function that strips all characters from a string except for A-Z 0-9 and run the $_POST through it? May I have an example? Code <?php include("core/connection.php"); if (!empty($_POST)) { $stid = oci_parse($conn, "SELECT CustomerNo FROM Customers WHERE Username = '" . $_POST['username'] . "' AND Password = '" . $_POST['password'] . "'"); oci_execute($stid); $count = oci_fetch

php_oci8 not loading on wamp server 2.0?

一世执手 提交于 2019-12-10 23:31:59
问题 I enabled the extension on wamp (Screenshot) but I still get this error: Fatal error: Call to undefined function oci_connect() in C:\wamp\www\wp1\wp-content\plugins\hrf\tmp.php on line 4 How can I solve this problem? Thank you. 回答1: Uninstall WAMP, Install ZendServer Community edition. Maybe it is not a right answer for your question, but it definitely works. ZendServer is most stable PHP stack. But if you want to keep WAMP, try this: make sure you have enabled extension=php_oci8.dll in your

pdo_oci make does not work

[亡魂溺海] 提交于 2019-12-10 14:49:25
问题 Recently I updated my opensuse 12.3 to the newer 13.1 Unfortunately, I'm not able to compile the pdo_oci.so needed. Using this guide, y could compile the extnention on 12.3: http://forums.opensuse.org/english/other-forums/development/programming-scripting/418966-installing-pdo_oci-php.html But unfortunately on the actual version i'm struggling to find a solution. At the moment i'm trying to execute the make, but y get the following error: /home/temp/PDO_OCI-1.0/pdo_oci.c:34:1: error: unknown

php oci_bind_by_name float to numeric

女生的网名这么多〃 提交于 2019-12-10 14:44:56
问题 I need to bind floating point number to OCI statement. What I'm doing: $price = 0.1 oci_bind_by_name($resource, 'price', $price); In my Oracle DB 'price' is an argument of the stored procedure and it's type is NUMERIC. After executing my statement I'm getting the following error: Message: oci_execute() [function.oci-execute]: ORA-06502: PL/SQL: numeric or value error: character to number conversion error ORA-06512: at line 1 If $price is an integer everything works fine. In PHP docs http://lv

PHP Warning at startup while trying to load php_oci8.dll

混江龙づ霸主 提交于 2019-12-10 14:14:20
问题 I'm using XAMPP and trying to configure Oracle connection for sql. I uncommented the line extension=php_oci8.dll and at first it ended up with an error (that oci.dll is missing), but later I downloaded instantclient from Oracle web pages. I tried with versions 10.2, 11.2, and 12.1 but neither worked. Obviously I've added the path to those libraries to my PATH env variable. The warning I'm getting at the startup of Apache is: PHP Warning: PHP Startup: in Unknown on line 0 The error when I'm

Connect to Oracle with odp.net and the OCI from C#

狂风中的少年 提交于 2019-12-10 11:25:31
问题 I have been reading about how to connect to my oracle database from my C# win application, but I keep “hitting the wall”. I have decided to use odp.net and OCI, such that the client computer not needs to install a client, but I can’t get it to work. I have a small test application, the code I shown below and in my solution I have added the following dll’s from oracle OCI: oci.dll, orannzsbb11.dll and oraociicus11.dll. They are all placed together with the final .exe file. Test Code: private

Call an Oracle stored procedure via OCI and return the results with an out ref cursor in C++

大城市里の小女人 提交于 2019-12-09 03:54:28
问题 I would like to call an Oracle stored procedure from C++ using the OCI interface and iterate over the results using an out SYS_REF_CURSOR as a parameter to the procedure. I'm new to OCI so might be missing something simple. Most of this code is taken from here: https://community.oracle.com/thread/507765?start=0&tstart=0 My stored procedure is: CREATE OR REPLACE PROCEDURE FXT_TEST_CALL(CRESULTS OUT SYS_REFCURSOR) IS sTESTQUERY VARCHAR2(4000); BEGIN sTESTQUERY := ' SELECT set_nam, cc_type from

install and configure OCI8 to connect oracle to php

假装没事ソ 提交于 2019-12-09 01:31:23
问题 I installed oracle 11g and I did create some tables and manipulate it using sql developer, and I am looking for a way to connect oracle with php on hosting site. I tried but I get error after using this code: $Conexion_ID =oci_connect($OracleUser, $OraclePassw, $OracleIP); this is the error: Call to undefined function oci_connect() I've known that I should install and configure OCI8, so I downloaded this file: http://www.oracle.com/technetwork/database/features/instant-client/index-097480

How to get number of rows in php oci for SELECT statement

一曲冷凌霜 提交于 2019-12-08 13:01:42
问题 I require help to get number of rows from select statement which contain where clause. I have tried various option. But it didn't work for me. I have shown my code snippet below. I'm getting o/p "0 rows fetched". But when I executed select query on Oracle DB, then it returns 1 row. Hence, please help me to get number of select statement in PHP through OCI. Environment: Windows, Php 7.3 and Oracle 12c Here is the Oracle query CREATE TABLE users ( no INTEGER NOT NULL, id VARCHAR2(200) NOT NULL,