Feed aggregator

count the number of execution for a specific SQL

Tom Kyte - Fri, 2018-02-23 22:46
Hello, I need a query to count the number of executions and the CPU time for those executions for a specific SQL_ID in the last hour. background: we have a simple query which executed very frequently by our customers and it takes 0.3 sec (usua...
Categories: DBA Blogs

Redo log archived but not applied in DR.

Tom Kyte - Fri, 2018-02-23 22:46
Greetings, I have configured DG with maximum availability with one primary and one standby. It was working okay and real time redo transport was applying fine. Now, the problem is :: Archived log is being transmitted to Standby but is not...
Categories: DBA Blogs

how to handle errors in oracle parallel function

Tom Kyte - Fri, 2018-02-23 22:46
I have parallel function like which takes cursor as input and creates flat file using UTL_FILE <code> CREATE OR REPLACE FUNCTION generate_file (p_input IN SYS_REFCURSOR) RETURN dump_ntt -- this just a nested table PIPELINED PARALLEL...
Categories: DBA Blogs

Can i give different permission SELECT/INSERT to same Schema for different application in one database?

Tom Kyte - Fri, 2018-02-23 22:46
Hi sir, I am DBA and now i stuck in one situation, I have one database and 3 different application, data will be come from one application and I need to store those data in one schema. Now, Scenario is 2 application can have read only access ...
Categories: DBA Blogs

database performance select count

Tom Kyte - Fri, 2018-02-23 22:46
Hi Team , i have query mentioned below : T1(id number , name varchar2 (20)); Column ID is full of null in table T1. select count(*) from table t1 where id is not null and name like :b1; This query is going on FTS , so we rewritten i...
Categories: DBA Blogs

database performance latch free

Tom Kyte - Fri, 2018-02-23 22:46
Hi Team, when latch contention is seen in database , how to identify type of latch and how to proceed for further troubleshooting? Additionally , if we want find latch type from ash , how to figure it from ASH , i see P1,P@ value are provided b...
Categories: DBA Blogs

PLSQL_OPTIMIZE_LEVEL 3 produces wrong function result

Tom Kyte - Fri, 2018-02-23 22:46
We looked into tuning our PL/SQL codebase and tested with all our packages compiled with PLSQL_OPTIMIZE_LEVEL 3. At first glance everything worked, but then our code started to act weird. After some investigation we found out, that PLSQL_OPTIMIZE_...
Categories: DBA Blogs

oci-utils (oracle cloud infrastructure) for Oracle Linux package

Wim Coekaerts - Fri, 2018-02-23 10:53

We recently added another little utilities RPM for Oracle Linux 7 to our collection:

oci-utils is an Oracle Linux RPM that contains a set of scripts to make managing an OCI instance easier, from within the instance.

The current version provides tools that help with managing block volumes (attach, remove, automatic discovery), secondary vnic configuration, a script to query the public IP of an instances and a script that lets you query instance metadata key/value pairs without having to parse or read json.

# yum install oci-utils Package content:

Binaries:
/usr/bin/oci-iscsi-config /usr/bin/oci-metadata /usr/bin/oci-network-config /usr/bin/oci-public-ip System service
/etc/systemd/ocid.service /usr/libexec/ocid MAN pages
oci-iscsi-config(1) oci-metadata(1) oci-network-config(1) oci-public-ip(1) ocid(8)
Ideally you start the ocid service, it will monitor for any changes in block devices or vnic's attached or removed. Today, when you add a block device, you have to run a number of iscsiadm commands to actually discover it and attach it to your instance. When ocid is running, it will, on a regular basis, probe to see if these devices have been created through the OCI web console, cli or SDK. It will then automatically disover them for you.

oci-iscsi-config is a simple wrapper around iscsiadm that provides you with a single command to list and attach/detach devices without having to know the iscsiadm command syntax.

ex:

# oci-iscsi-config -s For full functionality of this utility the ocid service must be running The administrator can start it using this command: sudo systemctl start ocid.service ocid already running. Currently attached iSCSI devices: Target iqn.2015-02.oracle.boot:uefi Persistent portal: 169.254.0.2:3260 Current portal: 169.254.0.2:3260 State: running Attached device: sda Size: 46.6G Partitions: Device Size Filesystem Mountpoint sda1 544M vfat /boot/efi sda2 8G swap [SWAP] sda3 38G xfs /

<attach a 50G block volume in the OCI webconsole>

# oci-iscsi-config -s Currently attached iSCSI devices: Target iqn.2015-12.com.oracleiaas:31b78e27-0c73-43ff-98b9-0ced1722a08c Persistent portal: 169.254.2.2:3260 Current portal: 169.254.2.2:3260 State: running Attached device: sdb Size: 50G File system type: Unknown Mountpoint: Not mounted Target iqn.2015-02.oracle.boot:uefi Persistent portal: 169.254.0.2:3260 Current portal: 169.254.0.2:3260 State: running Attached device: sda Size: 46.6G Partitions: Device Size Filesystem Mountpoint sda1 544M vfat /boot/efi sda2 8G swap [SWAP] sda3 38G xfs /

You can see /dev/sdb now show up after a few seconds, without having to run any commands.

oci-network-config is similar

oci-network-config is similar # oci-network-config -s CONFIG ADDR SPREFIX SBITS VIRTRT NS IND IFACE VLTAG VLAN STATE MAC VNIC - 10.0.0.2 10.0.0.0 24 10.0.0.1 - 0 ens3 - - UP 02:00:17:01:ed:6b ocid1.vnic.oc1.iad.abuwcljs4ik52qrq7itbb32rwajjqddt7utla64t47fkkq7tebw5gknt5csa <add a secondary interface>
# oci-network-config -s CONFIG ADDR SPREFIX SBITS VIRTRT NS IND IFACE VLTAG VLAN STATE MAC VNIC - 10.0.0.2 10.0.0.0 24 10.0.0.1 - 0 ens3 - - UP 02:00:17:01:ed:6b ocid1.vnic.oc1.iad.abuwcljs4ik52qrq7itbb32rwajjqddt7utla64t47fkkq7tebw5gknt5csa ADD 10.0.0.3 10.0.0.0 24 10.0.0.1 - 1 ens4 - - UP 02:00:17:01:eb:53 ocid1.vnic.oc1.iad.abuwcljsxek2mqaotafcohdmvghzrzx3jiiwq3zo45fh65dvlkpinndfjvma oci-public-ip just contacts an internet facing server to return your public IP of your instance.

# oci-public-ip Public IP address: 129.213.44.98
oci-medata let's you pretty-print the instance metadata and query for a given key

# oci-metadata -g region Instance details: Region: iad (Ashburn, VA, USA) # oci-metadata -g state Instance details: Instance state: Running

An updated version in the near future will also use the SDK (if installed along with your pem key) to go and create a block device and attach it from within your instance and/or create a secondary vnic and automatically create and attach it.

One roadmap item is the ability to use dynamic groups and principals to allow for an instance with the right privileges to do the block volume create/secondary vnic create without a pem key.

give it a try.

How to prevent RMAN archivelog backup from log switch

Yann Neuhaus - Fri, 2018-02-23 06:18

When RMAN backups archivelogs, it does a logswitch before backing up all archivelogs. In some cases this log switching should be suppressed. This can be done with expression “until time ‘sysdate'”, which actually filters nothing.

For example:

backup archivelog until time 'sysdate';
 

Cet article How to prevent RMAN archivelog backup from log switch est apparu en premier sur Blog dbi services.

Questions on DevOps, Graal, APIs, Git? Champs Have Answers at Oracle Code Los Angeles

OTN TechBlog - Fri, 2018-02-23 06:16

If you had technical questions about API design, for instance, or about date types in relational databases, or about DevOps bottlenecks, or about using Graal or Git,  you’d look for answers from someone with an abundance of relevant expertise, right? A champ in that particular topic.

As it happens, if you do indeed have questions on any of those topics, the Oracle Code event in Los Angeles on February 27 represents a unique opportunity for you to connect with a Developer Champion who can set you straight. Register now for Oracle Code Los Angeles, and put these sessions by Oracle Developer Champions on your schedule.

A Research Study Into DevOps Bottlenecks
Presented by: Baruch Sadogursky, Developer Advocate, JFrog
1:10 p.m.  - 1:55 p.m.  San Jose Room

Think DevOps is just so much hype? Guess again! “DevOps is among the none-hypish methodologies that really help,” said Developer Champion Baruch Sadogursky in a recent podcast. “It’s here to stay because it is another step toward faster and better integration between stakeholders in the delivery process.” But taking that step trips up some organizations. In this session Baruch dives deep into the results of a poll of Fortune 500 software delivery leaders to determine what’s causing the bottlenecks that are impeding their DevOps progress, and find solutions that will set them back on the path

Graal: How to Use the New JVM JIT Compiler in Real Life
by Christian Thalinger, Staff Software Engineer, Twitter, Inc.
2:10 p.m. - 2:55 p.m. San Francisco Room

Is Graal on your radar? It should be. It’s a new JVM JIT compiler that could become the default HotSpot JIT compiler, according to Developer Champion Christian Thalinger. But that kind of transition isn’t automatic. “One of the biggest mistakes people make when benchmarking Graal is that they assume they could use the same metrics as for C1 and C2” explains Christian. “Some people just measure overall time spent in GC and that just doesn't work.  I've seen the same being done to overall time spent for JIT compilations.  You can't do that." What can you do with Graal? Christian’s session will look at how it works, and what it can do for you.

Tackling Time Troubles - About Date Types in Relational Databases
by Bjoern Rost, Principal Consultant, The Pythian Group Inc
2:10 p.m. - 2:55 p.m. Sacramento Room

The thing about time is that it’s always passing, and there never seems to be enough of it. Things get even more complicated when it comes to dealing with time-related data in databases. While your mobile phone might easily handle leap years, time zones, or seasonal time changes, those issues can cause runtime errors, SQL code headaches, and other database problems you’d rather avoid. In this session Developer Champion Bjoern Rost will discuss best practices that will help you dodge some of the time data issues that can increase your aspirin intake. Put this session on your schedule and learn how to have an easier time when dealing with time data

Best Practices for API Design Using Oracle APIARY
by Rolando Carrasco, Fusion Middleware Director, S&P Solutions
Leonardo Gonzalez Cruz, OFMW Architect, S&P Soutions
 3:05 p.m.  - 3:50 p.m. San Jose Room

Designing and developing APIs is an important part of modern development. But if you’re not applying good design principles, you’re headed for trouble. “We are living in an API world, and you cannot play in this game with poor design principles,” says Developer Champion Rolando Carrasco. In this session, Rolando and co-presenter Leonardo Gonzalez Cruz will define what an API is, examine what distinguishes a good API, discuss the design principles that are necessary to build stable, scalable, secure APIs, and also look at some of the available tools. Whether you’re an API producer or an API consumer, you’ll want to take in this session.

Git it! A Primer To The Best Version Control System
by Bjoern Rost, Principal Consultant, The Pythian Group Inc
Stewart Bryson, owner and co-founder, Red Pill Analytics
4:20 p.m. - 5:05 p.m.  San Francisco Room

Git, the open source version control system, already has a substantial following. But whether you count yourself among those fans, or if you’re new and ready to get on board, this session by Bjeorn Rost and Oracle ACE Director Stewart Bryson will walk you through setting up your own Git repository, and discuss cloning, syncing, using and merging branches, integrating with CI/CD systems, and other hot Git tips. Don’t miss this opportunity to sharpen your Git skill

Of course, the sessions mentioned above are just 5 among 31 sessions, labs, and keynotes that are part of the overall Oracle Code Los Angeles agenda.

Don’t miss Oracle Code Los Angeles

Tuesday, February 217, 2018
7:30am - 6:00pm
The Westin Bonaventure Hotel and Suites
404 S Figueroa St.
Los Angeles, CA  90071
Register Now!

Learn about other events in the Oracle Code 2018 series
 

Related Resources

 

 

insert into remote database without using FORALL

Tom Kyte - Fri, 2018-02-23 04:26
I have a table with records more than million in a table in database1. I need to populate another table in database2 with some filters. BuLK forall insert is not allowed as these are remote DB. I need suggestion to populate remote database tabl...
Categories: DBA Blogs

Checking the checksum during purging process

Tom Kyte - Fri, 2018-02-23 04:26
Hi, We are developing an Archiving mechanism in which there is a procedure defined in the package that achieves the old partitions(according some business logic). We don't purge the partition as soon as it gets archived. We truncate the partition af...
Categories: DBA Blogs

SYS_CONNECT_BY_PATH reduce PATH to 2 specific levels

Tom Kyte - Fri, 2018-02-23 04:26
Hi, After looking through plenty of your previous examples i would like to piggy back from an example used many moons ago and ask for a change to the displayed result. https://asktom.oracle.com/pls/asktom/f%3Fp%3D100:11:0::::P11_QUESTION_ID:907...
Categories: DBA Blogs

Cursor_Sharing

Tom Kyte - Fri, 2018-02-23 04:26
Tom, We have an interesting problem, When we set cursor_sharing to 'force', doing following SQL having space trailing the return value 'Y'. SQL> select 'Y' from dual; SQL> 'Y' SQL> -------------------------------- SQL> Y However, a...
Categories: DBA Blogs

ODA – manually resetting a CPU alert using Fault Manager

Yann Neuhaus - Fri, 2018-02-23 02:16

While supporting since several years ODAs of different generations and versions, we faced time to time some hardware alerts sent back by the ILOM. However all of them are not related to real hardware issues and are false positive. To get rid of them the solution is to reset them manually.

When an hardware error occurs the first reaction is to open a Service Request and to provide an ILOM snapshot to the support. This can easily be done using the Maintenance menu in the ILOM web interface.

Based on support feedback, they may confirm that this alert is simply a false positive. Another solution if support answer is too slow is simply to give a try  :-D
However this will need a server reboot to ensure the alert really disappeared.

Here an example of a fault alarm about CPU we faced:

Date/Time                 Subsystems          Component
------------------------  ------------------  ------------
Tue Feb 13 14:00:26 2018  Power               PS1 (Power Supply 1)
        A loss of AC input power to a power supply has been detected.
        (Probability:100, UUID:84846f3c-036d-6941-eaca-de18c4c236bd,
        Resource:/SYS/PS1, Part Number:7333459, Serial
        Number:465824T+1734D30847, Reference
        Document:http://support.oracle.com/msg/SPX86A-8003-EL)
Thu Feb 15 14:27:04 2018  System              DBP (Disk Backplane)
        ILOM has detected that a PCIE link layer is inactive. (Probability:25,
        UUID:49015767-38b2-6372-9526-c2d2c3885a72, Resource:/SYS/DBP, Part
        Number:7341145, Serial Number:465136N+1739P2009T, Reference
        Document:http://support.oracle.com/msg/SPX86A-8009-3J)
Thu Feb 15 14:27:04 2018  System              MB (Motherboard)
        ILOM has detected that a PCIE link layer is inactive. (Probability:25,
        UUID:49015767-38b2-6372-9526-c2d2c3885a72, Resource:/SYS/MB, Part
        Number:7317636, Serial Number:465136N+1742P500BX, Reference
        Document:http://support.oracle.com/msg/SPX86A-8009-3J)
Thu Feb 15 14:27:04 2018  Processors          P1 (CPU 1)
        ILOM has detected that a PCIE link layer is inactive. (Probability:25,
        UUID:49015767-38b2-6372-9526-c2d2c3885a72, Resource:/SYS/MB/P1, Part
        Number:SR3AX, Serial Number:54-85FED07F672D3DD3, Reference
        Document:http://support.oracle.com/msg/SPX86A-8009-3J)

 

We can see that there are indeed 3 alerts for this issue.

In order to reset such an alert, you need first to log in on the server as root and access the IPMI tool

[root@oda-dbi01 ~]# ipmitool -I open sunoem cli
Connected. Use ^D to exit.

Oracle(R) Integrated Lights Out Manager

Version 4.0.0.28 r121827

Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.

Warning: password is set to factory default.

Warning: HTTPS certificate is set to factory default.

Hostname: oda-dbi01-ilom

 

Once in IPMI, you can list the Open Problems to get the same output than above using the following command:

-> ls /System/Open_Problems

In the list of the Open Problems we can find the UUID of the concerned component (see 3rd line)

Thu Feb 15 14:27:04 2018  Processors          P1 (CPU 1)
        ILOM has detected that a PCIE link layer is inactive. (Probability:25,
        UUID:49015767-38b2-6372-9526-c2d2c3885a72, Resource:/SYS/MB/P1, Part
        Number:SR3AX, Serial Number:54-85FED07F672D3DD3, Reference
        Document:http://support.oracle.com/msg/SPX86A-8009-3J)

 

Now it is time to access the fault manager to reset all alerts related to this UUID

-> cd SP/faultmgmt/shell/
/SP/faultmgmt/shell

-> start
Are you sure you want to start /SP/faultmgmt/shell (y/n)? y

 

The reset of the alert is done with the fmadm command

faultmgmtsp> fmadm acquit 49015767-38b2-6372-9526-c2d2c3885a72

At this point the alerts are already removed from the Open problems. However to make sure the issue is really gone, we need to reboot the ODA and check the Open Problems afterwards.

Note that I presented here the way to check Open Problems using the IPMI command line, but the same output is also available in the ILOM web page.

Hope it helps!

 

 

Cet article ODA – manually resetting a CPU alert using Fault Manager est apparu en premier sur Blog dbi services.

Upcoming FMW/WLS for EBS Webinar - OAUG AppsTech 2018

Steven Chan - Fri, 2018-02-23 02:00

The Oracle E-Business Suite Release 12.2 technology stack employs Oracle Fusion Middleware (FMW) 11g, including Oracle WebLogic Server (WLS).

Join us for this upcoming webinar and learn about administration, configuration and troubleshooting of these key components of the current EBS architecture.

  • Presenters: Kevin Hudson (EBS Development), Elke Phelps (EBS Product Management)
  • Title: Oracle E-Business Suite 12.2: Fusion Middleware (WebLogic Server) Administration
  • Date and Time: Tuesday, February 27, 2018, 1:00 p.m. EST (6.00 p.m. GMT)

You can register here for this OAUG AppsTech eLearning Series session.

A complete listing of sessions for the OAUG AppsTech eLearning Series is available on the OAUG website.

References
Categories: APPS Blogs

Installing the Oracle ODBC Driver on macOS

Christopher Jones - Thu, 2018-02-22 23:25

A bonus for today is a guest post by my colleague Senthil Dhamotharan. He shares the steps to install the Oracle Instant Client ODBC driver and the unixODBC Driver Manager on macOS.

ODBC is an open specification for accessing databases. The Oracle ODBC driver for Oracle Database enables ODBC applications to connect to Oracle Database. In addition to standard ODBC functions, users can leverage Oracle specific features for high performance data access.

Install the unixODBC Driver Manager
  • Download unixODBC from ftp.unixodbc.org/pub/unixODBC. I used unixODBC-2.3.1.tar.gz.

  • Extract the package:

    tar -zxvf unixODBC-2.3.1.tar.gz
  • Configure unixODBC:

    cd unixODBC-2.3.1 ./configure

    Note if you use the configure option "--prefix" to install into locations other than the default directory (/usr/local) then macOS's SIP features may prevent the unixODBC libraries being located correctly by the ODBC driver.

  • Build and install unixODBC:

    make sudo make install
Install the Oracle ODBC Driver
  • Download the Oracle 12.2 Instant Client Basic and ODBC packages from Instant Client Downloads for macOS (Intel x86).

    To reduce the installation size, the Basic Light package be used instead of Basic, if its character sets and languages are sufficient.

  • Extract both ZIP files:

    unzip instantclient-basic-macos.x64-12.2.0.1.0-2.zip unzip instantclient-odbc-macos.x64-12.2.0.1.0-2.zip

    This will create a subdirectory instantclient_12_2

  • The Oracle Instant Client libraries need to be in the macOS library search path, generally either in /usr/lib/local or in your home directory under ~/lib. I did:

    mkdir ~/lib cd instantclient_12_2 ln -s $(pwd)/libclntsh.dylib.12.1 $(pwd)/libclntshcore.dylib.12.1 ~/lib
  • With version 12.2, a small patch to the driver name in instantclient_12_2/odbc_update_ini.sh is required on macOS. I changed line 101 from:

    SO_NAME=libsqora.so.12.1

    to

    SO_NAME=libsqora.dylib.12.1
  • Run the configuration script

    cd instantclient_12_2 sudo odbc_update_ini.sh /usr/local sudo chown $USER ~/.odbc.ini

    This creates a default DSN of "OracleODBC-12c"

  • Edit the new ~/.odbc.ini configuration file and add the Oracle Database connection string. My database is running on the same machine as ODBC (inside a VirtualBox VM) and has a service name of 'orclpdb', so my connection string is 'localhost/orclpdb'. I changed:

    ServerName =

    to

    ServerName = localhost/orclpdb
Verify the installation

Run the isql utility to verify installation. Pass in the DSN name, and an existing database username and password:

$ isql OracleODBC-12c scott tiger +---------------------------------------+ | Connected! | | | | sql-statement | | help [tablename] | | quit | | | +---------------------------------------+ SQL>

You can execute SQL statements and quit when you are done.

Test Program

To test a program that makes ODBC calls, download odbcdemo.c.

  • Edit odbcdemo.c and set the USERNAME and PASSWORD constants to the database credentials.

  • Build it:

    gcc -o odbcdemo -g -lodbc odbcdemo.c
  • Run it

    ./odbcdemo

The output will be like:

Connecting to the DB .. Done Executing SQL ==> SELECT SYSDATE FROM DUAL Result ==> 2018-02-21 02:53:47 Summary

ODBC is a popular API for accessing databases. The Oracle ODBC Driver is the best way to access Oracle Database.

Resources

Using the Oracle ODBC Driver.

Oracle ODBC Drivers

Discussion Forum

Oracle Instant Client ODBC Release Notes

Instant Client Downloads

Installing XAMPP for PHP and Oracle Database

Christopher Jones - Thu, 2018-02-22 22:19

Today's guest post comes from Tianfang Yang who's been working with the Oracle Database extensions for PHP.

This post shows how to install XAMPP on Windows to run PHP applications that connect to a remote Oracle Database.

XAMPP is an open source package that contains Apache, PHP and many PHP 'extensions'. One of these extension is PHP OCI8 which connects to Oracle Database.

To install XAMPP:

  1. Download "XAMPP for Windows" and follow the installer wizard. I installed into my D: drive.

  2. Start the Apache server via the XAMPP control panel.


    screenshot of XAMPP control panel
  3. Visit http://localhost/dashboard/phpinfo.php via your browser to see the architecture and thread safety mode of the installed PHP. Please note this is the architecture of the installed PHP and not the architecture of your machine. It’s possible to run a x86 PHP on an x64 machine.


    screenshot of PHP configuration showing the PHP OS architecture as x86
  4. [Optional] Oracle OCI8 is pre-installed in XAMPP but if you need a newer version you can download an updated OCI8 PECL package from pecl.php.net. Pick an OCI8 release and select the DLL according to the architecture and thread safety mode. For example, if PHP is x86 and thread safety enabled, download "7.2 Thread Safe (TS) x86". Then replace "D:\xampp\php\ext\php_oci8_12c.dll" with the new "php_oci8_12c.dll" from the OCI8 PECL package.


    screenshot of PECL OCI8 download page

  5. Edit "D:\xampp\php\php.ini" and uncomment the line "extension=oci8_12c". Make sure "extension_dir" is set to the directory containing the PHP extension DLLs. For example,

    extension=oci8_12c extension_dir="D:\xampp\php\ext"
  6. Download the Oracle Instant Client Basic package from OTN.

    Select the correct architecture to align with PHP's. For Windows x86 download "instantclient-basic-nt-12.2.0.1.0.zip" from the Windows 32-bit page.


    screenshot of Oracle Instant Client download page
  7. Extract the file in a directory such as "D:\Oracle". A subdirectory "D:\Oracle\instantclient_12_2" will be created.

    Add this subdirectory to the PATH environment variable. You can update PATH in Control Panel -> System -> Advanced System Settings -> Advanced -> Environment Variables -> System Variables -> PATH. In my example I set it to "D:\Oracle\instantclient_12_2".

  8. Restart the Apache server and check the phpinfo.php page again. It shows the OCI8 extension is loaded successfully.


    screenshot of PHP configuration page showing a section for OCI8

    If you also run PHP from a terminal window, make sure to close and reopen the terminal to get the updated PATH value.

  9. To run your first OCI8 application, create a new file in the XAMPP document root "D:\xampp\htdocs\test.php". It should contain:

    <?php error_reporting(E_ALL); ini_set('display_errors', 'On'); $username = "hr"; // Use your username $password = "welcome"; // and your password $database = "localhost/orclpdb"; // and the connect string to connect to your database $query = "select * from dual"; $c = oci_connect($username, $password, $database); if (!$c) { $m = oci_error(); trigger_error('Could not connect to database: '. $m['message'], E_USER_ERROR); } $s = oci_parse($c, $query); if (!$s) { $m = oci_error($c); trigger_error('Could not parse statement: '. $m['message'], E_USER_ERROR); } $r = oci_execute($s); if (!$r) { $m = oci_error($s); trigger_error('Could not execute statement: '. $m['message'], E_USER_ERROR); } echo "<table border='1'>\n"; $ncols = oci_num_fields($s); echo "<tr>\n"; for ($i = 1; $i <= $ncols; ++$i) { $colname = oci_field_name($s, $i); echo " <th><b>".htmlspecialchars($colname,ENT_QUOTES|ENT_SUBSTITUTE)."</b></th>\n"; } echo "</tr>\n"; while (($row = oci_fetch_array($s, OCI_ASSOC+OCI_RETURN_NULLS)) != false) { echo "<tr>\n"; foreach ($row as $item) { echo "<td>"; echo $item!==null?htmlspecialchars($item, ENT_QUOTES|ENT_SUBSTITUTE):"&nbsp;"; echo "</td>\n"; } echo "</tr>\n"; } echo "</table>\n"; ?>

    You need to edit this file and set your database username, password and connect string. If you are using Oracle Database XE, then the connect string should be "localhost/XE".

    The SQL query can also be changed. Currently it queries the special DUAL table, which every user has.

  10. Load the test program in a browser using http://localhost/test.php. The output will be the single value "X" in the column called "DUMMY".


You can read more about PHP OCI8 in the PHP manual, and in the free Underground PHP and Oracle Manual from Oracle.

Enjoy your coding with OCI8!

Oracle Container Runtime for Docker 17.12

Wim Coekaerts - Thu, 2018-02-22 13:44

Busy news day!

We just updated our docker-engine rpm to version 17.12. As always you can find it in the Oracle Linux 7 preview channel on our yum server.

docker-engine-17.12.0.ol-1.0.1.el7.x86_64.rpm

We are currently cooking/baking "Oracle Container Services for Use with Kubernetes 1.9.1" stay tuned for that one as well.

oh and look for the docker-engine RPM on ARM soon too.

New OA Framework 12.2.6 Update 10 Now Available

Steven Chan - Thu, 2018-02-22 11:16

Web-based content in Oracle E-Business Suite Release 12 runs on the Oracle Application Framework (also known as OA Framework, OAF, or FWK) user interface libraries and infrastructure.

We periodically release updates to Oracle Application Framework to fix performance, security, and stability issues.

These updates are provided in cumulative Release Update Packs, and cumulative Bundle Patches that can be applied on top of the Release Update Packs. In this context, cumulative means that the latest RUP or Bundle Patch contains everything released earlier.

The latest OAF update for Oracle E-Business Suite Release 12.2.6 is now available:

Oracle Application Framework (FWK) Release 12.2.6 Bundle 10 (Patch 27308923:R12.FWK.C)

Where is this update documented?

Instructions for installing this OAF Release Update Pack are in the following My Oracle Support knowledge document:

Who should apply this patch?

All Oracle E-Business Suite Release 12.2.6 users should apply this patch. Future OAF patches for EBS Release 12.2.6 will require this patch as a prerequisite. 

What's new in this update?

This bundle patch is cumulative: it includes all fixes released in previous EBS Release 12.2.6 bundle patches.

In addition, this latest bundle patch includes fixes for the following issues:

  • When a Descriptive Flexfield (DFF) is in an advanced table under a query bean, some of its segments may not be displayed. Instead, other columns of the table may be repeated, or the same segment may be repeated.

Related Articles

Categories: APPS Blogs

Pages

Subscribe to Oracle FAQ aggregator