Skip to Main Content

Breadcrumb

Question and Answer

Chris Saxon

Thanks for the question, Fahd.

Asked: October 06, 2018 - 1:46 pm UTC

Last updated: October 10, 2018 - 1:34 am UTC

Version: 5.1.4.00.08

Viewed 1000+ times

You Asked

i have to call oracle report rdf,rep from apex, i have some fields like DATE_FROM and DATE_TO in apex form.
i want to generate url dynamically based on data from date_from and date_to fields by pressing button. i have used window.open('') in dynamic action execute javascript code, but i can not concatenate DATE_FROM and DATE_TO values.
example of url

http://localhost:8080/reports/rwservlet?report=myreport.rdf&userid=user/pass@xe&DATE_FROM='06-OCT-18'&DATE_TO='06-OCT-18'

And if there is some better way to call oracle report from apex, please guide.




and Connor said...

but i can not concatenate DATE_FROM and DATE_TO values.

Why not? You're just building a string no?

$v("MY_APEX_ITEM")

lets you access the value of an item in Javascript.


In any event, you might want to consider using a keymap file

https://docs.oracle.com/cd/E16764_01/bi.1111/b32121/pbr_run013.htm

to hide things like username etc. You still need to pass custom parameters


Rating

  (2 ratings)

Is this answer out of date? If it is, please let us know via a Comment

Comments

Thanks

Fahd Bahoo, October 08, 2018 - 6:50 am UTC

Thanks Connor,

its working now. could not find this way $v("MY_APEX_ITEM"). i was using :MY_APEX_ITEM and v("MY_APEX_ITEM"). did not know about $v("").

But if i want to get value from database and then concatenate, can it do it in java script dynamic action
Connor McDonald
October 10, 2018 - 1:34 am UTC

If the value you need is not already in an item, you could have a PLSQL process that gets the database value into a hidden item, and the follow that with the javascript.

Thanks

Fahd Bahoo, October 10, 2018 - 9:13 am UTC

Thanks Connor,

You helped a lot.

More to Explore

APEX

Keep your APEX skills fresh by attending their regular Office Hours sessions.