Skip to content

Tag: oracle

How to resolve the invalid number in orcale

I am facing an issue with some data that start with a strange character before the number 5 how can I discover all of these characters and remove it what do you recommend to resolve this issue knowing that I get the data from a specific source so I can not change anything but I am trying to mask it

Altering Oracle Sequence with result of two subqueries

I am trying to alter a sequence with the result of two subqueries. I am new with Oracle and stuck with a syntax. If you can, please help me with this : Upon Executing this, I am getting an “invalid number” error. What am I missing here? Answer You’ll definitely want PL/SQL and dynamic SQL, b…

ORA-01861: the value does not match the format string

I have this External Table: I created this function to return the week number of the year If I only run the function it tells me that everything has been compiled. But when i run the SELECT it gives me the following error: [I enter the dates like this: ‘2020/01/01’ but sql-developer on the control…

Difference between Global temporary table (GTT) and collections

I wanted to know the difference between GTT and collections with scenarios where to use GTT and where to use collections. Answer Global Temporary Tables are permanent data structures. We can manipulate data in a GTT using SQL like any other table. What distinguishes them from regular heap tables is: Their dat…

Min & Max date before disruption

In Oracle, I have this table sample : +————+————+————+————+ | EMPLOYEENO | DATE_FROM | DATE_TO | REASON | +————+————+————+——&#8212…

how to divide the amount for each record on specific condition

I have a table let’s assume X and I want to join it to another table Y this the content of X table Y If I made a relationship between X & Y tables the amount it will be duplicated, so if I used sum function the total will be wrong I decided to divide the amount between the stores