DBA Blogs

How to use conditional case with aggregate function

Tom Kyte - Mon, 2018-06-11 15:46
I have a query like the one below: SELECT CH.BLNG_NATIONAL_PRVDR_IDNTFR CASE WHEN CH.TCN_DATE BETWEEN TO_DATE('01-JAN-2016','DD/MM/YYYY') AND TO_DATE('30-JUN-2016','DD/MM/YYYY') THEN ROUND(SUM(CH.PAID_AMOUNT)/COUNT(DISTINCT CH.MBR_IDENT...
Categories: DBA Blogs

Conversion of Date format

Tom Kyte - Mon, 2018-06-11 15:46
I am having Column value as 'YYYYDDMM' and need to convert into 'DD/MM/YYYY' and store the data.
Categories: DBA Blogs

extract only two digit after fraction

Tom Kyte - Mon, 2018-06-11 15:46
For example, My query is following input data is in number format :- 123.456 and I want to see 123.45. Not need round off.
Categories: DBA Blogs

alter database noarchivelog versus flashback

Tom Kyte - Mon, 2018-06-11 15:46
SQL> alter database noarchivelog; alter database noarchivelog * ERROR at line 1: ORA-38774: cannot disable media recovery - flashback database is enabled
Categories: DBA Blogs

Can you Override USER built-in function ?

Tom Kyte - Mon, 2018-06-11 15:46
Hi Tom, Good Morning. My question may be naive, I'm not an Oracle expert. Can the USER built-in function be overridden ? Context: My current team has used Oracle for decades ( along with power-builder). We are now transitioning to a n...
Categories: DBA Blogs

New FY19 Cloud Platform Specializations Available

Showcase your expertise and distinguish yourself in the market by achieving one or more of our 120+ product and solution specializations. Specialized partners are recognized by Oracle and preferred...

We share our skills to maximize your revenue!
Categories: DBA Blogs

New Video : Online Relocation of a Pluggable Database

Hemant K Chitale - Fri, 2018-06-08 23:09
I have published a new YouTube Video:    Online Relocation of a Pluggable Database.

.
.
.
Categories: DBA Blogs

SYSDATE and the At sign

Tom Kyte - Thu, 2018-06-07 01:46
Hello. I've seen this code <code>"sysdate@!"</code> used in a program, and i became curios, as I couldn't find any documentation of it. From what I saw, both give the same result: <code>select sysdate@!, sysdate from dual;</code> So my qu...
Categories: DBA Blogs

Is there a way to bulk collect into associate array in 10G?

Tom Kyte - Thu, 2018-06-07 01:46
Hi Tom. First of all, I just want to say thank you for creating such a forum. I have just started using Oracle and have learnt a lot from you here. Now, my question is as follows: Let's say I have a table with 3 columns: create table T (col1 n...
Categories: DBA Blogs

Declare a variable of type DATE using var

Tom Kyte - Thu, 2018-06-07 01:46
Tom, How do I declare a variable of type DATE in SQL*Plus? All I see is CHAR/NCHAR, VARCHAR2/NVARCHAR2, CLOB/NCLOB, REFCURSOR, NUMBER, BINARY_FLOAT and BINARY_DOUBLE. Thanks...
Categories: DBA Blogs

How to Remove Japanese SEO Spam from your Website ?

iMERGE Group - Wed, 2018-06-06 11:51
Discovering the Hack1. Identify infected pages using Google Search
You can uncover such pages by opening Google Search and searching for:
site:[your site root URL] japan
Navigate through some pages of the search results to see if you discover any suspicious looking URLs. These are the pages indexed by Google containing the word ‘japan’. If you notice pages with the Japanese characters in the title or description, it is likely that your website is infected.
Japanese SEO Spam in Google Search Results

2. Verify with Security Issues Tool in Google Search Console
In your Google Search Console (earlier called Google Webmaster Tools), navigate to the Security Issues Tool in the left sidebar.
Google Search Console Security Issues Tool
3. Fetch as Google to check for ‘Cloaking’
When you visit any of these hacked pages, you might see a 404 not found page suggesting that the web page doesn’t exist. Be careful, the hacker may be using a technique called cloaking. Check for clocking by using the “Fetch as Google” tool in your Google Search Console.
Fixing the Japanese SEO Spam Hack1. Remove any newly created user accounts in the Search Console
If you don’t recognize any users in the “Users and Property Owners” tab, immediately their revoke access. Websites hacked with the Japanese SEO Spam add spammy Gmail accounts as admins so that they can change your site’s settings like sitemaps and geotargeting.
2. Run a Malware Scan
Scan your web server for malware and malicious files using the ‘Virus Scanner’ tool in the cPanel provided by your web host.
3. Check your .htaccess file
Hackers often use the .htaccess file to redirect users and search engines to different malicious pages. Verify the contents of the .htaccess file from a last known clean version of the file from your backups. If you find any suspicious code, comment it out by putting the ‘#’ character in front of the rule.
4. Check Recently Modified Files
Login to your web server via SSH and execute the following command to find the most recently modified files:
find /path-of-www -type f -printf '%TY-%Tm-%Td %TT %p\n' | sort -r
If you are an Astra customer, you would have received an email telling you about malicious file changes.
5. Check your Sitemap
A hacker may modified, or added a new sitemap to get the Japanese SEO Spam pages indexed quickly. If you notice any suspicious links in the sitemap, ensure that you quickly update your CMS core files from a last known clean backup.
 6. Prevent future attacks with a Website Firewall
Another option to prevent the Japanese SEO Spam infections is to use a Website Firwall.


If you are still looking for an expert then feel free to reach out to us at support@ingressit.com and someone from our team will surely help you. 


Categories: DBA Blogs

interpret trace file

Tom Kyte - Wed, 2018-06-06 07:26
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options Windows NT Version V6.2 CPU : 12 - type 8664, 6 Physical Cores Process Af...
Categories: DBA Blogs

SQL statements inside AWR views

Tom Kyte - Wed, 2018-06-06 07:26
Hi Tom, I'm trying to find the history of executions for a given sql statement by using AWR views like DBA_HIST_ACTIVE_SESS_HISTORY, DBA_HIST_SQLSTAT, DBA_HIST_SQLTEXT, DBA_HIST_SQL_PLAN etc. I find the SQL_IDs for SQL by querying DBA_HIST_SQLT...
Categories: DBA Blogs

Display master child data as a set - from 2 different tables

Tom Kyte - Wed, 2018-06-06 07:26
Hi , I will be glad if you could help me in this. I have a Parent Table ( ORDER_HEADER ) and a Child table ( ORDER_LINE ). They are linked by order_id. ORDER_HEADER holds order details for customers and ORDER_LINE holds the child lines for ea...
Categories: DBA Blogs

Parsing a CLOB field with CSV data and put the contents into it proper fields

Tom Kyte - Wed, 2018-06-06 07:26
My Question is a variation of the one originally posted on 11/9/2015. parsing a CLOB field which contains CSV data. My delimited data that is loaded into a clob field contains output in the form attribute=data~ The clob field can contain up to 6...
Categories: DBA Blogs

process limit and sessions

Tom Kyte - Wed, 2018-06-06 07:26
Hi there, For the past few days,during the peak hours i am getting the following error in a frequent way " Listener refused the connection with the following error: ORA-12519, TNS:no appropriate service handler found " I googled it first,...
Categories: DBA Blogs

Which is default if session is interrupted - COMMIT or ROLLBACK?

Tom Kyte - Wed, 2018-06-06 07:26
Hi Tom, I use Oracle SQL Developer. I do not use autocommit and in normal situation I always use after some block of SQL commands (INSERT, DELETE etc.) COMMIT, or ROLLBACK. But what does happen if I do not finish this block of SQL command in...
Categories: DBA Blogs

Composite Range-Hash interval partitioning with LOB

Tom Kyte - Tue, 2018-06-05 13:06
Hi, I would like to partition a table with a LOB column using Range-Hash interval partitioning scheme. But I not sure how the exact partition gets distributed in this scenario and also I noticed following differences based on how I specify my p...
Categories: DBA Blogs

Index Column Order – Impact On Index Branch Blocks Part I (Day-In Day-Out)

Richard Foote - Mon, 2018-06-04 07:16
I recently replied on Twitter to some comments regarding an excellent blog post by Franck Pachot – Covering indexes in Oracle, and branch size, where I disagreed somewhat with one of the conclusions stated in the post: “ensure that selective columns appear as early as possible (without compromising the index access efficiency of course) in order to […]
Categories: DBA Blogs

SID YES SERVICE_NAME NO in tnsnames.ora

Tom Kyte - Sun, 2018-06-03 06:06
Hello Tom, We use tnsnames.ora . 1) What is the difference between SID entry and SERVICE_NAME in the tnsnames.ora 2) When I put SID the connection is successful, when I put SERVICE_NAME it says tns could not resolve service name So This w...
Categories: DBA Blogs

Pages

Subscribe to Oracle FAQ aggregator - DBA Blogs