Division by zero
-
Yay! A new 12c misfeature!
Let me set the stage by pointing out that there are two types of clients...the "thin" client and the OCI client. "Thin" is what developers would generally use for stuff and the OCI is what you put on servers. Or at least, we do. It's my understanding that the OCI version handles clusters or whatever shit that you want on a server but don't really care for doing your development. Who the fuck
knowscares?Anywho...if you're using the thin client and your DB password is within 7 days of expiring, you get an error message:
ORA-28002: the password will expire within 7 days
OK, that's easy enough to deal with. But...if you're running the OCI client, you get something like this:
oracle.jdbc.driver.OraclePreparedStatement.<init>(OraclePreparedStatement.java:1387) java.lang.ArithmeticException: / by zero
Which is kind of scary to have happen when you haven't changed anything.
Fuck you Oracle. Fuck you.
-
At Oracle, division by zero is called 'corporate restructuring'.
-
ic aside: In actual mathematics (as opposed to the sub-sub-sub-set taught in primary and secondary school), the problem with division by zero is not that it doesn't have an answer, but that the answer it gives is dependent on the branch of mathematics you are working in and the type of subspace, manifold, or numeric domain you are working on. The 'No Meaningful Value' or 'NaN' interpretation is the one that is most often useful, but is not the only possible one, nor the only one actually used in real-world mathematics (mostly various forms of transfinite domains, IIRC hyperreals is one of those).
-
@ScholRLEA You could almost say it was... undefined.
-
@error Why yes, you could.
-
@error said in Division by zero:
@ScholRLEA You could almost say it was... undefined.
-
-
@ben_lubar said in Division by zero:
@error said in Division by zero:
@ScholRLEA You could almost say it was... undefined.
I find that object objectionable.
-
@FrostCat said in Division by zero:
@ben_lubar said in Division by zero:
@error said in Division by zero:
@ScholRLEA You could almost say it was... undefined.
I find that object objectionable.
Objectification!
-
TIL that trying to divide by 0 might cause demons to fly out of my nostrils! :D
-
@Erufael Careful, I hear Oracle charges a lot for those.
-
@ScholRLEA In engineering it's usually classified as "fuck it, close enough!".
-
@boomzilla said in Division by zero:
@Erufael Careful, I hear Oracle charges a lot for those.
-
@boomzilla said in Division by zero:
is within 7 days of expiring
Solution 1: Don't let passwords expire
Solution 2: Set a cron job so that every day, it checks for passwords that are within 7 days of expiring, and sets them to be 8 days instead.Problem solved.
E_CLOSED_WONTFIX_ORACLE_SAYS_FUCKYOU
-
@Lorne-Kates Solution is simple when you know the reason. The difficult part is to find out the reason.
Apparently the message the OCI throws out is not helpful for you to figure out what's going on. Most user will simply assume there is a bug in their code instead of seeing it's a problem generated from Oracle.
Note to myself. The next time I work on software that interacts with Oracle, if some bug comes out and there's nothing be changed for some time, assume it's Oracle's problem.
-
@Lorne-Kates said in Division by zero:
E_CLOSED_WONTFIX_ORACLE_SAYS_FUCKYOU
Closing as won't fix? Amateurs! Just add a note on page 15989628 of the manual which documents the behavior. Then you can label it a documentation bug and claim you've fixed it.
-
@Lorne-Kates said in Division by zero:
Solution 1: Don't let passwords expire
Solution 2: Set a cron job so that every day, it checks for passwords that are within 7 days of expiring, and sets them to be 8 days instead.I'm not the guy with the permission to do any of that (nor do I want any Oracle administrative responsibilities). I'm just the poor schmuck who has to do the DBA's job in figuring out what the problem is.
-
Ah, password expiry. I never heard of that misfeature being used for database connections, but I'm not enterprise grade either.
-
(8/0).toString()[3] > "i"
see, part of dividing by 0 is imaginary?
-
@gleemonk said in Division by zero:
Ah, password expiry. I never heard of that misfeature being used for database connections, but I'm not enterprise grade either.
Hey, password expiration is a good security feature because it... Uh... Well... It makes users make better passwords... Err no, uh, um.... It... Uh.... Yeah no no idea.
-
@sloosecannon said in Division by zero:
Hey, password expiration is a good security feature because
it... Uh... Well... It makes users make better passwords... Err no, uh, um.... It... Uh.... Yeah no no ideathe security experts say it is and the auditors will give you grief if you don't implement it.FTFY
-
@antiquarian said in Division by zero:
@sloosecannon said in Division by zero:
Hey, password expiration is a good security feature becauseit... Uh... Well... It makes users make better passwords... Err no, uh, um.... It... Uh.... Yeah no no ideathe "security experts" say it is and the "auditors" will give you grief if you don't implement it.FTFY
FTFTFYFY
-
-
@antiquarian said in Division by zero:
@accalia said in Division by zero:
FTFTFYFY
Sure, but the auditors are real.
so are the experts. it doesn't make them any less of a bunch of quacks
-
@darkmatter turn it into a javascript battle....
!((9/0)[9/0]+++"")[9/0] >true
clearly not dividing by zero enough is true
-
-
@accalia said in Division by zero:
it doesn't make them any less of a bunch of quacks
You know you have a problem when your experts are called Huey, Louie and Dewey.
-
@dkf What about when the CFO is named Uncle Scrooge?
-
@gleemonk I know where I used to work we had password expiration on for our application accounts on
Oracle. Apparently there was some security policy that required it.Which is annoying because our DBA didn't always track when the passwords would expire, so one of the apps would suddenly stop working.