# Dremio with Oracle 12g datasource, views was working on version less than v20

**URL:** <https://community.dremio.com/t/dremio-with-oracle-12g-datasource-views-was-working-on-version-less-than-v20/8813>\
**Category:** Uncategorized\
**Created:** [March 2, 2022, 5:46pm UTC](https://community.dremio.com/t/dremio-with-oracle-12g-datasource-views-was-working-on-version-less-than-v20/8813 "2022-03-02T17:46:11Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![The\_Yab974](https://avatars.discourse-cdn.com/v4/letter/t/9de053/32.png) [@The\_Yab974](https://community.dremio.com/u/The_Yab974)\
**Post date:** [March 2, 2022, 5:46pm UTC](https://community.dremio.com/t/dremio-with-oracle-12g-datasource-views-was-working-on-version-less-than-v20/8813/1 "2022-03-02T17:46:11Z")

</div>

Hi.

I’ve upgraded v11 to v20 cause of elasticsearch v7 support particularly. Got some Oracle datasource connected and some views which are working without major error in v11. When i’ve upgraded to v20 some views needed some adjustements.

I’ve noticed that some Oracle function seems to not have been pushed down correctly. I’ve compensate with dremio function when it could be. (i couldn’t for some regexp one). But now i’ve got a big view which makes me an error when i make a request on it just with simple select with a simple criteria : “GandivaException: Failed to make LLVM module due to Function string castVARCHAR(date64[ms], int64) not supported yet.”

I can’t figure out how to fix it.

Can you help me?

---

<div class="post-metadata">

**Author:** ![The\_Yab974](https://avatars.discourse-cdn.com/v4/letter/t/9de053/32.png) [@The\_Yab974](https://community.dremio.com/u/The_Yab974)\
**Post date:** [March 3, 2022, 1:54pm UTC](https://community.dremio.com/t/dremio-with-oracle-12g-datasource-views-was-working-on-version-less-than-v20/8813/2 "2022-03-03T13:54:47Z")

</div>

Hi.

I’ve made some test to try to resolve the pb, and it seems that when reflection is enabled, the exception disappears… How could it be possible?

Thx.

---

<div class="post-metadata">

**Author:** ![balaji.ramaswamy](https://sea2.discourse-cdn.com/flex020/user_avatar/community.dremio.com/balaji.ramaswamy/32/843_2.png) [@balaji.ramaswamy](https://community.dremio.com/u/balaji.ramaswamy)\
**Post date:** [March 4, 2022, 2:51am UTC](https://community.dremio.com/t/dremio-with-oracle-12g-datasource-views-was-working-on-version-less-than-v20/8813/3 "2022-03-04T02:51:35Z")

</div>

@The_Yab974 Are you able to provide us with a profile for the job that failed with the Gandiva exception?

---

<div class="post-metadata">

**Author:** ![The\_Yab974](https://avatars.discourse-cdn.com/v4/letter/t/9de053/32.png) [@The\_Yab974](https://community.dremio.com/u/The_Yab974)\
**Post date:** [March 4, 2022, 6:19am UTC](https://community.dremio.com/t/dremio-with-oracle-12g-datasource-views-was-working-on-version-less-than-v20/8813/4 "2022-03-04T06:19:52Z")

</div>

Sure. I’ve made some other tests and with another comparison operator for my criteria the exception disappears too… (\>= instead of = which fails)

[60f5b4de-813d-4fe3-8a78-3b5c4a59fb68.zip](https://community.dremio.com/uploads/short-url/eJD86AWDUXEoxvseFIvdYDWRuRD.zip) (692,6 Ko)

---

<div class="post-metadata">

**Author:** ![The\_Yab974](https://avatars.discourse-cdn.com/v4/letter/t/9de053/32.png) [@The\_Yab974](https://community.dremio.com/u/The_Yab974)\
**Post date:** [March 15, 2022, 1:02pm UTC](https://community.dremio.com/t/dremio-with-oracle-12g-datasource-views-was-working-on-version-less-than-v20/8813/5 "2022-03-15T13:02:49Z")

</div>

Hi.

I wanted to share my experience about this result.

It seems that it’s due to introducing last\_day() function in dremio set instead of passing through to the DB (Oracle here). Since Dremio v16 (i’ve upgraded from v11 to v20 as a reminder but honestly i haven’t read all release note. My bad…) this function return timetype now where previously it returned string. So as required for our views we passed some string conversion function in this situation which results on this bug.

After adapting request it works perfectly.

Best regards.

---

<div class="post-metadata">

**Author:** ![balaji.ramaswamy](https://sea2.discourse-cdn.com/flex020/user_avatar/community.dremio.com/balaji.ramaswamy/32/843_2.png) [@balaji.ramaswamy](https://community.dremio.com/u/balaji.ramaswamy)\
**Post date:** [March 25, 2022, 3:36am UTC](https://community.dremio.com/t/dremio-with-oracle-12g-datasource-views-was-working-on-version-less-than-v20/8813/6 "2022-03-25T03:36:50Z")

</div>

Thanks for the update @The_Yab974

Super nice that you figured it out and apologize for the delay

---

<div class="post-metadata">

**Author:** ![The\_Yab974](https://avatars.discourse-cdn.com/v4/letter/t/9de053/32.png) [@The\_Yab974](https://community.dremio.com/u/The_Yab974)\
**Post date:** [March 25, 2022, 5:21am UTC](https://community.dremio.com/t/dremio-with-oracle-12g-datasource-views-was-working-on-version-less-than-v20/8813/7 "2022-03-25T05:21:06Z")

</div>

Don’t worry. I understand. This tool is great and if i can help (and have time for it ofc) i share my experience with pleasure.

If only everything in this world could be like that… 😉
