Friday, August 26, 2022

Why customers choose Oracle Linux to run their applications on OCI

Oracle Linux is a highly performant and secure operating environment. Oracle Linux delivers virtualization, management, automation, cloud native computing tools, and the operating system in a single, easy-to-manage support offering. It powers Oracle Cloud Infrastructure (OCI), Oracle Cloud Applications, and Oracle Engineered Systems. Oracle Linux is a proven and highly secure and reliable platform for Oracle and non-Oracle applications alike. Thousands of Oracle Cloud customers worldwide and thousands of independent software vendors who certify their software on it.

Oracle Linux Support is included at no extra cost with your OCI subscription. You can take advantage of all the benefits Oracle Linux Support provides, including access to the latest packages and updates, 24/7 expert support, My Oracle Support portal with an extensive Linux knowledge base, Oracle Ksplice zero-downtime updates, Oracle Autonomous Linux, and OS Management Service to manage and monitor Oracle Linux instances, and more. Oracle Linux on OCI also provides you with a single point of contact for support across cloud infrastructure, the operating system, and Oracle software.

Oracle Linux for your OCI application workloads

Here are 12 great reasons to consider Oracle Linux for your application workloads in OCI:

◉ Ksplice zero-downtime updates: Using Ksplice, your Oracle Linux kernel and user space are updated and patched with all the latest critical fixes without incurring operational costs or planned downtime. Ksplice is installed and enabled by default for Oracle Linux instances in OCI.

◉ Frequent Oracle Linux image updates: Oracle Linux images available on OCI are frequently updated to help ensure access to the latest software.

Oracle Database Exam, Oracle Database Prep, Database Career, Database Jobs, Database Skills, Database Certification

◉ Optimized Linux development platform: Easy access to Linux developer and preview software channels is available from the Oracle Linux yum server. Thousands of EPEL packages available under the EPEL channel are built and signed by Oracle for security and compliance. We also support Software Collection Library to enable developers to install recent versions of Python, PHP, NodeJS, Nginx, and more, without the risk of disrupting applications running on different versions of these components.

◉ Enhanced cloud developer experience: Oracle Cloud developer tools, such as Terraform infrastructure orchestration software, software development kits (SDKs), and OCI command line interface (CLI), are easily deployed through Oracle-provided yum server RPMs. The Oracle Linux Cloud Developer image is also an OCI-provided Platform image available for the x86_64 and Arm architectures that enables you to rapidly preinstall, automatically configure, and deploy a comprehensive development environment on OCI. It includes a choice of popular development languages, OCI client tools, database connectors and other tools that can be deployed in minutes, all with a single image from the Oracle Cloud Console.

◉ Automated OS management: Oracle OS Management service is an OCI integrated solution that helps automate common management tasks for Oracle Linux and Windows Server systems. It provides update and package management and security and compliance reporting tools. Using the Resource Discovery and Monitoring feature, you gain visibility into Oracle Linux CPU and memory utilization and top processes to help identify and resolve system performance bottlenecks.

Oracle Database Exam, Oracle Database Prep, Database Career, Database Jobs, Database Skills, Database Certification

◉ Autonomous Linux operation: Based on Oracle Linux, Oracle Autonomous Linux runs in OCI and is managed with OS Management service. It automatically handles management tasks, including patching with zero downtime without human intervention. It monitors critical OS events and helps keep systems highly secure, save labor costs, and achieve higher availability.

Oracle Database Exam, Oracle Database Prep, Database Career, Database Jobs, Database Skills, Database Certification

◉ Comprehensive containers and container management support: Oracle Container Registry acts as a trusted source for patched Oracle software container images. Oracle Linux Support is included for Oracle Container Runtime and Oracle Linux Container Services for use with Kubernetes.

◉ Faster downloads: The Oracle Linux yum server and Oracle Container Registry are mirrored inside OCI to enable faster downloads of the latest Oracle Linux bug fixes, security, and container images for Oracle software. Because all network traffic stays within the OCI data centers, no internet traffic bandwidth is consumed, and no network charges are incurred.

Oracle Database Exam, Oracle Database Prep, Database Career, Database Jobs, Database Skills, Database Certification

◉ Rapid deployment: OCI provides easy access and rapid instance deployment using Oracle Cloud Marketplace and OCI-provided partner images. With a few clicks, you can install Oracle Linux, Oracle Linux-based images such as Oracle Linux KVM, and Oracle Linux Cloud Developer images, and other Oracle and partner software directly from within the Oracle Cloud Console.

◉ Oracle Linux for Arm: Develop next-generation applications using Oracle Linux for Arm platform images deployed on Ampere Altra A1 Compute shapes in OCI.

Oracle Database Exam, Oracle Database Prep, Database Career, Database Jobs, Database Skills, Database Certification

◉ High-performance network file system (NFS) server with Oracle Linux Storage Appliance: Quickly and easily build NFS shared storage using NVMe devices attached to OCI bare metal and virtual machine (VM) Compute instances by using the Oracle Linux Storage Appliance image, available on the Oracle Cloud Marketplace. Oracle Linux and Autonomous Linux based images are both available.

◉ 100% application binary compatibility with Red Hat Enterprise Linux (RHEL): Existing RHEL applications can run without reinstallation or coding changes with Oracle Linux. You can receive support for your RHEL instances in OCI at no extra cost by switching yum to receive updates from the Oracle Linux yum server.

These features make Oracle Linux on OCI not only the most cost-effective and integrated OS in OCI, but it also provides the best application platform experience.

Discover the advantages on OCI


Oracle Linux is the recommended Linux distribution for Oracle applications and engineered to provide higher security, scalability, and reliability for your mission-critical workloads. Discover why so many enterprises rely on Oracle Linux on OCI today. You can start with an OCI account and resources using Oracle Cloud Free Tier credits.

Oracle Database Exam, Oracle Database Prep, Database Career, Database Jobs, Database Skills, Database Certification

Learn how to take advantage of Oracle Linux features and tools to enhance your application development and deployment experience in OCI by visiting Oracle Linux on OCI learning library.

Source: oracle.com

Wednesday, August 24, 2022

Convert your address data into geographic coordinates using Spatial Studio

You probably have address data stored in your Oracle Database, but now you want to visualize addresses on a map and do some spatial analysis or mining. You can´t do so by using the address information as is. What you need are geocoded addresses, meaning geographic coordinates for your locations.

To get started with geocoding, have a look at your address data. Make sure you understand how your addresses are specified and where you might have problems with the data quality.

To receive the best possible results while geocoding, we recommend having separate columns for the following address-type attributes:

◉ House number

◉ Street name

◉ City/Settlement

◉ Postal code

◉ State/Province

Our demo data set is a subset of publicly available and free address data is provided by Statistics Canada. Click here to download it. The complete data set you can download via this URL.

Let´s load the demo data into an Oracle Database using Spatial Studio.

Step 1: Create a data set

Start Spatial Studio and connect using your credentials. Click on the “Datasets” icon in the navigation pane on the left, then “Create Dataset”.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

Drag and drop the previously downloaded file (address_data_ca_subset.csv) into the “Create Dataset” dialog. Confirm with “Create”.

In “Create dataset from a CSV file” enter values for the following parameters or confirm the defaults:

◉ Upload to connection
◉ Table name
◉ Dataset name

Ensure the column names are valid and you have the correct data type assigned.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

If everything looks correct, click “Submit” and wait for the process to finish. You should then find the newly created data set.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

Step 2: Fix address data issues

You see a warning when looking at the icon left from the data set. This means that there are issues to be fixed first. Those issues could be:

◉ The definition of a unique key is missing.
◉ The geographic coordinates are missing.
◉ A spatial index is missing.

To identify what is missing from your data, click on the icon. You will get the following information:

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

Let´s fix the issues one by one. Start defining the key column by clicking “Go to Dataset Columns”.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

The column ID can possibly serve as a key column. Select it and check whether the values in this column are unique by clicking on “Validate key”.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

The key is valid. Therefore go ahead by clicking on “Apply”.

Note: If there is no suitable column in the data set that can serve as a unique key, you can select to create one by clicking on “Create Key Column”.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

For this option, click “Ok” and “Apply”.

Since the warning icon is still attached to the data set, we will work on the next issue, the missing coordinates. Remember, to derive the geographic coordinates from the address data, we need the geocoder to start working.

Click on the icon again and then select “Geocode Addresses”.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

Now the dialog opens where you can map the different columns in your data set to a geo-type that the geocoder requires.

Based on the column names, some columns have already been mapped to the best matching geo-type. It does not always have to be correct. Feel free to change the mapping to your needs if necessary.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

After you have mapped the columns, you also need to select the country. This is necessary because every country has its way of specifying address data. Selecting the State/Province is only recommended if the addresses can be fully assigned to one value. It is not the case for our demo data set.

Optionally, you can create two additional columns with the default names LONGITUDE and LATITUDE.

Now you are ready to start the geocoder. Click “Apply”.

It is time to take a break and get a coffee or tea since it takes a couple of minutes to geocode the entire data set.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

You can follow the progress of the geocoding process. The geocoder fetches the data batch by batch, calculates the coordinates for each batch, and writes the results back into the database. The batch size you can specify in the general settings of Spatial Studio. For now, it uses the default or whatever value you have set before.

If the status changes to “DONE” you can “Close” the dialog.

When finished, you can see that the warning icon is no longer there. Instead, you have a new icon that represents a location. This is your confirmation that the data set now has coordinates assigned and is ready to be visualized on a map.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

Let´s sidestep a bit and have a look at our database table using SQL Developer. We can see there that we have three new columns with data populated:

◉ LONGITUDE of type NUMBER
◉ LATITUDE of type NUMBER
◉ GC_GEOMETRY of type SDO_GEOMETRY

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

Step 3: Verify geocoding results

It’s common that not all addresses in a data set can be geocoded. Reasons include missing or incorrect data, affecting the quality of your data. Therefore, checking the geocoding results textually and visually is a good practice

Right-click on the data set. Select “Prepare” and then “Geocode Addresses”. By choosing the tab “Status”, you can find detailed information about how the geocoder has worked its magic. The result is also stored in the metadata repository of Spatial Studio and can be accessed directly via SQL. You can find the SQL statement in “Query all unmatched rows”.

Now, we want to have a closer look at the results.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

You get the following information:

◉ Geocoded: YES
◉ Number of rows (in the data set): 13062
◉ Matched (full matches): 12920
◉ Ambiguous (matches): 0
◉ Partial (matches): 142
◉ Unknown: 0
◉ Number of failed rows: 0

This is an excellent result. Is there room for improvement? Possibly.

Let´s switch to the tab “Partial Match”. Here we can see those addresses which could not be entirely mapped with the reference data the geocoder relies on.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

You can now manually edit the data. Let us do this for one of the addresses. Replace the following values for one of the addresses:

◉ STREET => TUNNEY’S PASTURE DRIVEWAY
◉ HOUSENO => 150
◉ POSTAL_CODE => K1A 0T6
◉ CITY => ONTARIO

Hold on, why should you store ONTARIO for CITY? There is no city with that name Canada. Relax. The geocoder has built-in features to also work if data is missing, wrong, or just misspelled. Hence let´s give it a try.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

Click on the “Actions” icon “Submit row to geocoder” and click on “Refresh” afterward. Now you should see a new value for LONGITUDE too.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

You cannot see that the values for LATITUDE and GC_GEOMETRY have also changed. But we will check it later and find out where this address is located.

Step 4: Update statistics

It is always a good practice for new data sets to have statistics in place, which also contain information about the bounding box around, a rectangle that defines the outer boundaries of your data set (also called layer in relation to maps). The bounding box focuses and centers the map when appropriately displayed.

Return to the “Datasets” menu and right-click on the data set. Select “Update statistics” and confirm with “OK”.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

Step 5: Plot your addresses on a map

Again, right-click on your data set and select “Create project”. This creates a new project with a map as a central component. Drag and drop your data set from the “Dataset” tree on the left onto the map. Voilà, here is your map with the geocoded addresses (look for green circle icons).

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic
Caption
 
Zoom in on the green circle(s) placed in the west of Canada. The more you zoom in, the more of your addresses are displayed.

Please note that you can change the style of the position icons. You can find descriptions of how to do so in the Spatial Studio documentation.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

Let’s find the address we have changed in step 3. Click on “…” right from the data set in the “Layers List” and select “Zoom to layer”.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

Now, zoom in on the green circle in the east of Canada.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

The tiny green circle on the underlying base map reveals the position of the address.  You can see it is on Tunney´s Pasture Driveway in Ottawa. So, this looks good, even though we have previously specified an incorrect value for the city name.

If you want to be as accurate as possible, you can again correct the address since you know that the city’s name is Ottawa. Go back to the data set and its geocoding results, edit the address, and re-submit it to the geocoder.

Oracle Database, Oracle Database Career, Oracle Database Skills, Oracle Database Jobs, Oracle Database Prep, Oracle Database Study, Oracle Database Tutorial and Materials, Oracle Database Skills, Oracle Database Jobs, Oracle Database Geographic

You get a full match now, and the edited address is removed from the list of partial matches.

Go back to your project and refresh the map layer. Not surprisingly, the geocoder was already right on its first attempt since the icon is still in the same place.

Source: oracle.com

Monday, August 22, 2022

[Neustar] SDO_POINTINPOLYGON for fast, high-volume spatial processing

Many location intelligence and geospatial applications need to perform high volumes of spatial queries daily – with fast performance to service critical business applications. Neustar operates a cloud-based analytics platform called ElementOne, which provides real-time lead scoring, custom segmentation, and market analytics for its SaaS customers worldwide. The ElementOne platform runs 24/7, conflating data from 200-plus sources.

Read More: 1Z0-1093-21: Oracle Cloud Database Services 2021 Specialist

ElementOne combines spatial analysis with sophisticated analytics and predictive modeling. This gives clients real-time insights into the effectiveness of their marketing programs and store siting plans. Because the data is sensitive and needs to be available on demand, workflows must be highly secure, scalable, available, and reliable. Read more about Neustar’s business challenges and other Oracle Database 19c features they use here.

In this blog post, Nick Salem, Distinguished Engineer at Neustar, describes a specific Oracle Spatial function and Oracle Database 19c global temporary tables, and how they help Neustar deliver location analytics quickly, at scale. Nick shows how to use the SDO_POINTINPOLYGON function to find all customers within a certain distance of a sales trade area, and shares performance results using large customer point data sets.

--

The SDO_POINTINPOLYGON function API is a great feature that was first released in Oracle Database 12c. There is a nice blog post that explains how this feature can be used to address the challenges of ingesting large amounts of spatial data where you can handle the loading and querying of large spatial data sets without the overhead associated with creating and maintaining a spatial index. The post shows how SDO_POINTINTPOLYGON can really benefit massive scale operations, such as those using Exadata environments.

In this post, I would like to cover some other benefits that the SDO_POINTINPOLYGON feature provides that can be very helpful – especially for applications servicing a large number of concurrent spatial operations. This can greatly improve performance for such applications that run on either Exadata or non-Exadata environments. The fact that the  SDO_POINTINPOLYGON does not use a spatial index means that you can leverage data stored in an external table, global temporary table and now in Oracle Database 19c, these can also include hybrid partitioned tables, private temporary tables or JSON datasets to perform spatial point-in-polygon queries. Global temporary tables are great for multi-session environments because every user session has their own version of the data for the same global temporary table, without any contention or row locking conflicts between sessions. Furthermore, since Oracle Database 12c, there have been some major performance optimizations to global temporary tables that result in substantially lower redo and undo generation. You will need to make sure the system parameter temp_undo_enabled is set to TRUE to ensure that the global temporary tables optimization is fully in effect.

Below is a screenshot from Neustar’s ElementOne platform with a map showing a trade area and set of uploaded customer points.

Core Java, Java Programming, Oacle Java Career, Java Skills, Java Jobs, Java Tutorial and Materials, Java Cloud, Oacle Java Certification, Java Preparation Exam

At Neustar, our clients work with a lot of transient work data as part of a multi-step process for various spatial and analytical use cases. Let’s put together a quick PL/SQL script that you can use to test drive the power of the SDO_POINTINPOLYGON function. Here, I use a simple polygon in the San Diego area and generate a set of random customer points in and around the polygon. Then, I populate the global temporary table. The script is configurable: you can increase or decrease the number of randomly generated customer points, and how far from the polygon centroid you may want to allow points to extend to. Once you have the data populated, you can run the SDO_POINTINPOLYGON queries in serial or in parallel, or change some of the optional MASK parameters. Here’s a screenshot of the test polygon and a sample of randomly generated 1000 customer points.

Core Java, Java Programming, Oacle Java Career, Java Skills, Java Jobs, Java Tutorial and Materials, Java Cloud, Oacle Java Certification, Java Preparation Exam

1. Create a global temporary table


Ok, so let’s first create a global temporary table =>

create global temporary table TMP_SPATIAL_POINT (
x          number,
y          number,
id         varchar2(512) )
on commit preserve rows

2. Generate a set of random points and populate the global temporary table


Next, let’s run the following script to populate table TMP_SPATIAL_POINT. The script has two variables: maxDistanceInMeters and numberOfPoints in the PL/SQL declaration section that you can adjust as needed. If you want to generate more points, then you can change the value of numberOfPoints from 1000 to a greater number. In this example, I also have maxDistanceInMeters set to 4000. This will ensure that no customer points get generated further than 4000 meters away from the polygon centroid; this can be increased or decreased as needed. The script goes through a loop up to the numberOfPoints variable and uses the SDO_UTIL.POINT_AT_BEARING function to plot points around the centroid of the polygon using randomly generated values. The goal of the script is to quickly create some test data you can play with. Of course, you can also change the test polygon as well.

declare
polygon                     sdo_geometry;
centroid                    sdo_geometry;
newPoint                    sdo_geometry;
maxDistanceInMeters         number := 4000;
numberOfPoints              number := 1000;
type tRecs                  is table of tmp_spatial_point%rowtype;
recs                        tRecs := tRecs();
begin
polygon := SDO_GEOMETRY(2003, 4326, NULL, SDO_ELEM_INFO_ARRAY(1,1003,1),
SDO_ORDINATE_ARRAY(-117.1044,32.680882,-117.08895,32.661808,-117.06148,32.675102, -117.06045,32.697641, -117.09753,32.696774, -117.1044,32.680882));
centroid := SDO_GEOM.SDO_CENTROID( polygon, 0.5 );
recs.extend(numberOfPoints);
for i in 1 .. numberOfPoints loop
  newPoint := SDO_UTIL.POINT_AT_BEARING( start_point => centroid,
                                         bearing => dbms_random.value(0,6.283),
                                         distance => dbms_random.value(1,maxDistanceInMeters));
  recs(i).id := i;
  recs(i).x := newPoint.sdo_point.x;
  recs(i).y := newPoint.sdo_point.y;
end loop;
delete from tmp_spatial_point;
forall i in recs.first .. recs.last
  insert into tmp_spatial_point values ( recs(i).x, recs(i).y, recs(i).id ) ;
commit;
end; 

3. Run SDO_POINTINPOLYGON queries (in serial or parallel)


Ok, now we can start performing queries using the SDO_POINTINPOLYGON function. Here’s a sample query that returns the counts of points that fall inside the polygon. The params parameter is optional; if omitted, a MASK=ANYINTERACT query will be performed.

set timing on
select
  count(*)
from
  table(
  SDO_PointInPolygon(
                      cur =>  cursor(select * from tmp_spatial_point),
                      geom_obj => SDO_GEOMETRY(2003, 4326, NULL,
                                              SDO_ELEM_INFO_ARRAY(1,1003,1),
                                              SDO_ORDINATE_ARRAY( -117.1044,32.680882,
                                                                  -117.08895,32.661808,
                                                                  -117.06148,32.675102,
                                                                  -117.06045,32.697641,
                                                                  -117.09753,32.696774,
                                                                  -117.1044,32.680882)),
                      tol => 0.05,
                      params => 'MASK=INSIDE'
                       )
  ) t  ;

Here's another example of the query using parallelism and with the params parameter omitted.

select /*+ parallel(8) */
  count(*)
from
  table(
  SDO_PointInPolygon(
                      cur =>  cursor(select * from tmp_spatial_point),
                      geom_obj => SDO_GEOMETRY(2003, 4326, NULL,
                                              SDO_ELEM_INFO_ARRAY(1,1003,1),
                                              SDO_ORDINATE_ARRAY( -117.1044,32.680882,
                                                                  -117.08895,32.661808,
                                                                  -117.06148,32.675102,
                                                                  -117.06045,32.697641,
                                                                  -117.09753,32.696774,
                                                                  -117.1044,32.680882)),
                      tol => 0.05
                       )
  ) t  ;

The SDO_POINTINPOLYGON function has been built to leverage Oracle’s parallel processing capability. To demonstrate the magnitude of performance gain when utilizing parallelism, I modified the point generation script in part 2 to populate two million points with a max distance of 5,000 meters from the center point. I then tested the SDO_POINTINPOLYGON query with no parallelism, and then with parallelism of 2, 4 and 8. Here are the elapsed response times:

Level of parallelism Elapsed time 
None  8.56 secs
5.61 secs 
3.18 secs 
1.96 secs 

Utilizing parallelism can greatly shorten query processing times. You can use these scripts in your environment to generate different numbers of points, test various levels of parallelism, and compare the response times.

Source: oracle.com

Saturday, August 20, 2022

Recent New Features in Oracle Graph

Feature Highlights

Path Visualization

The newest release of Oracle Graph includes a couple updates to path visualization for your graph queries. One is the ability to unnest the path in a graph query result, using the ONE ROW PER STEP syntax.

Here is an example:

SELECT v,e,v2

FROM MATCH ALL (a)-[:TRANSFERS]->{4}(b) ON bank_graph

ONE ROW PER STEP (v1, e, v2)

WHERE a.acct_id=934 AND id(a) = id(b)

Oracle Graph, Oracle Database Career, Database Skills, Database Jobs, Database Exam Study, Database Prep, Database Preparation, Database News

The INTERVAL Keyword when Using PGQL 

The newest release of Oracle Graph also includes the INTERVAL syntax in PGQL. This operates similarly to INTERVAL in PL/SQL, as it allows us to query and visualize using a period of time.

Here are some examples:

SELECT n.timestampProp
FROM MATCH (n) -> (m)
WHERE n.timestampProp < m.timestampProp + INTERVAL '1' DAY

SELECT n.timestampProp
FROM MATCH (n) -> (m)
WHERE n.timestampProp < INTERVAL '1' DAY + m.timestampProp
 
SELECT n.timestampProp
FROM MATCH (n) -> (m)
WHERE n.timestampProp > m.timestampProp - INTERVAL '1' DAY
 
Property Graph Support for SQL Developer

The PGQL Plugin for SQL Developer was recently released with SQL Developer 22.2. There are no additional settings, or plugins, required to use this feature of SQL Developer. This feature shows the list of PG Schema and PG Views in the connected database, and allows you to run CREATE, DROP, INSERT, DELETE, and SELECT queries through SQL Developer.

Oracle Graph, Oracle Database Career, Database Skills, Database Jobs, Database Exam Study, Database Prep, Database Preparation, Database News

Graph Client on Maven Central

Starting with version 22.4, the Property Graph Java client of Oracle Graph Server and Client can be obtained from Maven Central via the following dependency declaration:

<dependency>
  <groupId>com.oracle.database.graph</groupId>
  <artifactId>opg-client</artifactId>
  <version>22.3.0</version>
</dependency>

Or with the equivalent Gradle Declaration:

implementation group: 'com.oracle.database.graph', name: 'opg-client', version: '22.3.0'

With these declarations, you can easily access the Java client, and build out applications that can connect to an Oracle Database, read graphs into database memory, run algorithms on the graph and run PQGL queries on the graph.

Updates to Graph Studio on Autonomous Database


PGQL on RDBMS interpreter

The %pgql-rdbms interpreter executes PGQL queries directly against the underlying database, rather than against the %pgql-pgx, which runs queries against graph server. This feature also allows you to create graphs directly in the database using the PGQL-RDBMS interpreter. 

Oracle Graph, Oracle Database Career, Database Skills, Database Jobs, Database Exam Study, Database Prep, Database Preparation, Database News

Support for SPARQL UPDATE queries

Inserting and removing triples is now supported in the RDF Query Playground and with SPARQL interpreters. 

Source: oracle.com

Friday, August 19, 2022

Oracle Database Service for Microsoft Azure Technical Overview

In this blog post, we shed light into the finer details of the service’s architecture and building blocks, including its deep integration into the Azure stack.

Service Overview

Since 2019, we have partnered with Microsoft to deliver the OCI-Azure Interconnect, which offers secure, private interconnections with sub-2 millisecond latency, in 11 global regions to date.  This high-performance network foundation enables customers to build multicloud applications, with components straddling two clouds – OCI and Azure. However, the flexibliity to connect any resource in either cloud requires customers to configure and manage the connections between the cloud environments, DNS entries, and more, to run workloads across Azure and OCI.

The new ODSA service builds on the foundation of OCI-Azure Interconnect to simplify setup, management, and connectivity of application components in Azure to databases running in OCI. With ODSA, Azure teams can treat databases running on OCI like an Azure resource. In just a few clicks, users can connect their Azure subscriptions to their OCI tenancy. The service automatically configures everything required to link the two cloud environments and federates Azure active directory identities, making it seamless for Azure users to use the service. It provides an Azure like user interface and API experience for provisioning and managing Oracle database services on OCI. ODSA also sends metrics, logs, and events for the OCI databases you create using the service to Azure tooling for unified telemetry and monitoring in Azure environments. In addition, the service also simplifies customer support with a collaborative support model to offer a seamless issue resolution process that can be initiated with either Microsoft or Oracle.

Oracle Database Service, Microsoft Azure Technical, Oracle Database Career, Oracle Database Prep, Oracle Database Certification, Oracle Database Skills, Oracle Database Jobs, Oracle Database Preparation Exam
Figure 1 – Oracle Database Service for Azure Home Page

Let’s take a deeper look into how we built this service, including its architecture.  

Architecture


When you configure ODSA, the service deploys an Oracle Enterprise application in your Azure tenancy. This application enables you to provision Oracle databases for your Azure environment and manages connectivity to resources in your Azure tenancy. The service also creates custom roles in the application and custom groups in your tenant’s Azure Active Directory. You’ll assign roles or group membership to enable existing Azure users to use ODSA. With that in place, the service builds a mapping between one or more Azure subscriptions to your OCI tenancy.

As you can see from figure 2 below, ODSA builds a private tunnel between your Azure and OCI tenants. The service also configures DNS on both sides of the pipe to enable bi-directional communication between applications in your Azure tenant and database resources in OCI.

Oracle Database Service, Microsoft Azure Technical, Oracle Database Career, Oracle Database Prep, Oracle Database Certification, Oracle Database Skills, Oracle Database Jobs, Oracle Database Preparation Exam
Figure 2 – Oracle Database Service for Azure Architecture

Oracle Cloud Infrastructure Integration


At launch, the service supports creation and management of the following Oracle Cloud Database Service offerings: Autonomous Database, Exadata Database, and Base Database. We aim to add support for other Oracle Cloud Database Service offerings such as MySQL Heatwave, in due course.

For each database product, ODSA supports the common administration and application access capabilities:

◉ Create, read, update, delete, list (CRUDL)
◉ Clone database
◉ Database backup (automatic and manual)
◉ Database restore (restore to existing database for now)
◉ Generate Azure connection string
◉ Display database metrics

ODSA allows only authorized users to manage database resources created in ODSA. These database resources you create using ODSA, reside in OCI alongside any other resources you may have deployed in OCI. As mentioned previously, ODSA federates Azure active directory identities, so users log into ODSA using their Azure credentials. The identity federation is at a custom group level, ensuring only a subset of identities you desire are federated over to OCI. Recognizing that Azure administrators may want to control what authorized users can do in each environment (ODSA Portal and OCI Console), ODSA creates a robust set of custom roles for fine grained access in your Azure Active Directory. Administrators can set up access control down to the type of database product (Autonomous Database, Exadata Database etc.) giving customers maximum flexibility over how their environments work. ODSA also created a Read-Only role for organizations that require audit access to the Oracle environment.

Azure tools integration


For each database provisioned using ODSA, the service delivers OCI database metrics, events, and logs to tools such as Azure Application Insights, Azure Event Grid, and Azure Log Analytics. This enables Azure users to view OCI databases alongside the rest of your Azure data, for unified telemetry and monitoring. Additionally, ODSA also creates a custom dashboard that provides Azure developers with all the details they need about the Oracle database such as resource details, and connection strings for their applications.

Oracle Database Service, Microsoft Azure Technical, Oracle Database Career, Oracle Database Prep, Oracle Database Certification, Oracle Database Skills, Oracle Database Jobs, Oracle Database Preparation Exam
Figure 3 – Azure Custom Dashboard for Oracle Database

The custom dashboard also displays graphs for each of the standard Oracle database metrics for the resource, giving developers and administrators a quick view of all metrics in one place.

Oracle Database Service, Microsoft Azure Technical, Oracle Database Career, Oracle Database Prep, Oracle Database Certification, Oracle Database Skills, Oracle Database Jobs, Oracle Database Preparation Exam
Figure 4 – Azure Custom Dashboard Metrics for Oracle Database

Source: oracle.com

Monday, August 15, 2022

Oracle Database Service for Azure

Oracle Database Service, Oracle Database Exam, Database Certification, Database Career, Database Skills, Database Jobs, Oracle Database Guides

Oracle and Microsoft Simplify the Path to Multicloud Choice

Cloud has fundamentally changed the way organizations develop applications, secure data, and manage infrastructure. The ability to quickly provision resources, scale on demand, and deploy globally has created new opportunities to innovate. In 2022, IDC expects spending on cloud infrastructure to outpace non-cloud infrastructure for the first time.

The multicloud reality

As usage of cloud increases, enterprises are finding themselves in a multicloud environment where applications and data are deployed in more than one public cloud provider. According to IDC’s 2021 IaaSView survey of 1,500 cloud buyers, 64% of respondents currently have a multicloud environment. Of those, 75% have an application in one cloud that regularly interacts with databases located elsewhere (either another cloud or on-premises).

There are several factors driving the use of multiple clouds. For many, it is part of a best-of-breed approach to selecting cloud services. For others, it is a method of mitigating vendor lock-in and diversifying risk. Perhaps most important, companies have reported starting with one cloud provider but expanded to others due to technical or architectural limitations.

Those that are operating a multicloud environment are quick to identify the challenges. Each public cloud has a different workflow and set of management tools that inhibit interoperability. There is a lack of unified security and monitoring across providers that limits visibility and increases the potential for vulnerabilities. It also is difficult to share large amounts of data between clouds due to concerns about the performance (high-latency connections) and cost (data transfer fees).

While some cloud providers offer a limited set of tools to help with integration, the burden of integration is typically put on the customer to solve. This is not surprising from a business perspective, since many cloud providers would rather customers be all-in on their platform than facilitate a multicloud scenario.

Breaking the multicloud barrier

If you look inside the datacenters of most enterprises, you will likely find two familiar brands of applications: Oracle and Microsoft. As CIOs plan their migration to cloud, the ability to move those applications and databases without compromising performance and availability is critical. Committed to serving their common enterprise customer base, Oracle and Microsoft have been partnering on an innovative approach to multicloud.

The first example of this was the Oracle Cloud and Microsoft Azure Interconnect, originally launched in 2019. It currently consists of 11 interconnected regions with more planned in 2022. Customers worldwide have taken advantage of this service which eliminates ingress/egress charges between clouds, provides less than 2ms of latency, and has fixed pricing based on the circuit size. Since it is a standard offering, provisioning is quick and the service provides full access to the broad portfolio of OCI and Azure services.

This first offering served as a foundation for future collaboration. The next logical step is to make it easier for Azure customers to provision Oracle databases in OCI. These databases include:

◉ Oracle Autonomous Database: A fully automated database service with machine-learning-driven tuning, scaling, and patching, running atop Exadata.

◉ Exadata Database Service: Scale-out infrastructure with unique optimizations at the source code-level, providing extreme performance, availability, and security.

◉ Base Database Service: Oracle Enterprise Edition or Oracle Standard Edition databases on bare metal or virtual machines, available with Real Application Clusters (RAC).

The new service is called Oracle Database Service for Azure, which is described as an Oracle managed intercloud service that enables customers to easily provision and manage Oracle databases running on OCI using an Azure native API and console experience.

The intent behind this new service is to solve the most common challenges of multicloud by creating an automated and seamless experience. Oracle recognized that Azure customers may not be familiar with OCI terminology and constructs, so it created a portal that looks familiar to Azure users. The single interface makes it easy to link OCI and Azure accounts. It can even create an OCI account during the setup process, if needed.

Once the accounts are linked with a simple handshake, it is then possible to provision OCI databases which appear as resources in Azure. The service automates the process of identity, networking, and monitoring integration. Oracle Database Service for Azure is supported via a joint model, where a ticket can be initiated with either cloud provider and with a coordinated resolution response.

The new service solves a major problem for Azure customers with on-premises Oracle deployments, allowing them to migrate their RAC and Exadata systems to the cloud. Oracle indicates that once customers experience the benefits of RAC and Exadata on-premises, including zero downtime during failures or planned maintenance and Exadata's highly optimized performance, they want the architectural equivalent in the cloud. Now Azure users can now run their Oracle databases on Exadata in OCI using a simple Azure interface. It’s essentially like operating two clouds as one and enabling large Microsoft application accounts to replicate their Oracle-Microsoft experience in the cloud.

A multicloud future

All market indicators point to a multicloud future – one where customers can pick and choose the best services to meet their needs without compromise. Oracle and Microsoft are leading the way by delivering multicloud solutions that automate the most common provisioning tasks with a consistent and familiar user experience. This allows customers to have a “best of both worlds” approach, unlocking the full portfolio of OCI and Azure services.

Azure customers also get the opportunity to benefit from the unique commercial programs that OCI offers including Universal Credits, BYOL, and Support Rewards as well as consistent pricing across regions and low data egress fees. It would not be surprising for modern developers to use this service as their introduction to Oracle databases, especially for high-performance, mission-critical applications.

Oracle promises more to come with MySQL HeatWave availability for Azure later in 2022. When major cloud providers work together, it is the customer that ultimately wins.

Source: oracle.com