Oracle separation P and BPP

I’m reading (with much pleasure) the book Quantum Computing Since Democritus by Scott Aaronson. At some point the author claims that, while most most people believe that $ \mathbf{P} = \mathbf{BPP}$ in real life, it is very easy to construct an oracle $ O$ such that $ \mathbf{P}^O \neq \mathbf{BPP}^O$ . Frankly I don’t find this easy at all. Even more so I find it implausible sounding. I will explain my reasoning here.

My understanding from earlier parts of the book is that the reason people believe that $ \mathbf{P} = \mathbf{BPP}$ is that we believe in the existence of good pseudo-random generators (i.e. deterministic processes that generate random looking strings) and even have some plausible looking candidate pseudo-random generators. Now whenever we want to run a $ \mathbf{BPP}$ algorithm on a $ \mathbf{P}$ -machine we just run the algorithm as written, but replace every random bit the $ \mathbf{BPP}$ -machine would use by a pseudo-random bit generated by our pseudo-random generator.

You can see my problem now: we can just apply the same strategy in presence of the oracle. Whenever the $ \mathbf{BPP}^O$ -algorithm makes an ‘ordinary’ deterministic step we do the same thing in our $ \mathbf{P}^O$ algorithm. Whenever the $ \mathbf{BPP}^O$ -algorithm queries the oracle, we query the same oracle in our $ \mathbf{P}^O$ algorithm and whenever the $ \mathbf{BPP}^O$ -algorithm uses a random bit we use a bit from our pseudo-randomgenarator. What could go wrong, short of the oracle magically coming to life, taking physical form and smashing our pseudo-random generator with an axe? So my question is:

What is an example of an oracle $ O$ such that $ \mathbf{BPP}^O \neq \mathbf{P}^O$ and what problem is in the former but not the latter class?

Update: while typing the link the following question shows up that is essentially asking the same: Existence of suitable pseudo-random number generators to derandomize BPP to P

However I don’t see how the accepted answer answers my question. It seems to say that there are oracles that can distinguish the output of a given pseudo-random-generator from actually random data but

a) I can’t think of a problem where having access to truly random data would give an advantage over having access to only outputs of $ G$ to solve it and

b) What if the $ \mathbf{P}$ -machine fools the oracle by using a PRG other than $ G$ ?

Case inside case in oracle query

enter image description here

Can anyone help me?

I want to use query using CASE WHEN with logic where time less than 03:00 PM on Monday until Friday will get value start from tomorrow 03:00 PM until today 03:00 PM

  SELECT SUBSTR (A.TXT_TXN_DESC, 7, 15)                  AS billing_no,          TO_CHAR (dat_txn, 'dd/mm/yyyy hh24:mi:ss.')     AS waktu,          ''                                              AS note     FROM ncbshost.v_ch_nobook A    WHERE     cod_drcr = 'C'          AND (CASE                   WHEN (SELECT TO_CHAR (SYSDATE, 'dd/mm/yyyy hh24:mi:ss')                           FROM DUAL) <=                        TO_CHAR (SYSDATE, 'dd/mm/yyyy') || ' 15:00:00'                   THEN                       dat_txn BETWEEN (CASE                                            WHEN (SELECT TRIM (                                                             TO_CHAR (SYSDATE,                                                                      'DAY'))                                                    FROM DUAL) =                                                 'MONDAY'                                            THEN                                                TO_DATE (                                                       TO_CHAR (SYSDATE - 3,                                                                'dd/mm/yyyy')                                                    || ' 15:00:00',                                                    'dd/mm/yyyy hh24:mi:ss')                                            ELSE                                                TO_DATE (                                                       TO_CHAR (SYSDATE - 1,                                                                'dd/mm/yyyy')                                                    || ' 15:00:00',                                                    'dd/mm/yyyy hh24:mi:ss')                                        END)                                   AND TO_DATE (                                              TO_CHAR (SYSDATE, 'dd/mm/yyyy')                                           || ' 15:00:00',                                           'dd/mm/yyyy hh24:mi:ss')                   ELSE                       a.dat_txn BETWEEN TO_DATE (                                                TO_CHAR (SYSDATE, 'dd/mm/yyyy')                                             || ' 15:00:00',                                             'dd/mm/yyyy hh24:mi:ss')                                     AND TO_DATE (                                                TO_CHAR (SYSDATE, 'dd/mm/yyyy')                                             || ' 23:59:59',                                             'dd/mm/yyyy hh24:mi:ss')               END) ORDER BY SUBSTR (A.TXT_TXN_DESC, 7, 15) ASC 

Is it possible to do ‘Oracle Cloud Infrastructure Certifications’ without following ‘SQL Fundamentals | 1Z0-06’? [on hold]

I recently switched my career from SE to Oracle DBA. Currently, the company that I’m working is in progress of switching to a cloud system. As a beginner is it possible to do complete ‘Oracle Cloud Infrastructure Certifications’ without ‘SQL Fundamentals | 1Z0-06’.And note that, I do have good self-studied architectural knowledge about oracle DB and good experience in SQL and PLSQL(from my previous SE career)

How to fix Swingbench schemas so they could be used for Oracle 18c

Swingbench 2.6 supports Oracle 12c and I have been used it for 12c successfully. But I want to use Oracle 18c for testing purposes.

In case of installing schemas using wizards from swingbench\winbin folder I was getting scripts hanging except oewizard script and could only run CRUD tests with it using SYSTEM user instead of SOE.

How to fix Swingbench scripts so they could be used for 18c also, especially cc, sh and json wizard scripts?

Contar registros en Query – ORACLE

Tengo una consulta muy simple que no logro acomodar, anexo mi query:
























Ésta consulta al ejecutarla, me arroja 3 registros, lo cual está excelente, pero necesito que en el último campo el cual llamo como “NULL AS PRORRATEO”, necesito que me cuente la cantidad de registros (3) entre el total de “Costo Oferta” que en esta caso es un costo de $ 20,000.

En teoría el campo de PRORRATEO requiero que me realice la división del total del costo oferta (20,000) entre la cantidad de registros que mando llamar en mi consulta (3) y en dicho campo me pueda mostrar 6,666.66 lo equivalente a 20,000 / 3.

HELP no soy muy buena en esto aún =(

Conexion JAVA NetBeans con Oracle 12C

Hola a todos esperando se encuentren bien.

Estoy usando JAVA NetBeans 8.2 y tengo credenciales para conectarme a una base de datos Oracle Enterprise 12c dicha base de datos ya le he conectado con Oracle Developer en mi PC local sin problemas.

Ahora quiero desarrollar una aplicación JAVA para realizar las consultas al servidor donde se aloja la base de datos, pero me arroja error en la conexion.

java.sql.SQLException: No suitable driver found for ………….

Estas son las lineas de conexion: // Load the JDBC Driver Class.forName(“oracle.jdbc.driver.OracleDriver”);

// Create a connection Connection con = DriverManager.getConnection( “jdbc.url=jdbc:oracle:thin:@//”, “Usuario”, “Password”);

Descargue el driver: ojdbc7.jar

Alguna idea de cual podria ser el error?


Windows has crashed suddenly it was includes Oracle DB

I had Oracle database XE 11G on windows 7 , but DB installation files (Old oradata , fast_recovery , product and admin) on partition (D) that is save .. I have installed fresh windows with same old name and installed new Oracle DB with same path without taking any RMAN or HOT backup , what is the steps to replace new DB files with old ?? I need to access to my old database.


Baker, Gill, Solovay – construction of oracle B such that P^B != NP^B

I have some questions about Baker, Gill, Solovay proof of the existence of an oracle such that P^B != NP^B. The proof can be found in Siam Journal of Computing, 4:432-442, 1975 [219].

  • Why Isn’t this construction considered a counterexample to P = NP? And if it is not, can it be strengthened into one? It seems tome that we have constructed a languge recognizable in NP time but not in P time.

  • In the proof there is the sentence “If P_i^B(i) accepts 0^n, then place no string into B at this stage.” How can this possibly happen?

I figured that, since B is intially empty, the oracle B(i) ALWAYS rejects. So the only reason why P_i would accept is some reason OTHER than a question to B(i). Please correct me if I am wrong.

The proof in question is verbatim reproduced here. The original paper is here.