Home » Developer & Programmer » Application Express, ORDS & MOD_PLSQL » VBA and mod_plsql
VBA and mod_plsql [message #209208] Wed, 13 December 2006 15:41 Go to next message
sparrow
Messages: 8
Registered: November 2006
Junior Member
Hi all

I am building a VBA application that will call an Oracle procedure using mod_plsql.

I have built the URL in my VBA module, which looks like 'http://<my server>:<port>.pls/mydad/myproc?param1=1234. I have my package set up in the Oracle database as well.

My (hopefully) simple question is how do I send the URL to Oracle?

Another question. When I log the user in, how do I keep them logged in? I'm assuming I can create a cookie for the session?

Thanks
Re: VBA and mod_plsql [message #209602 is a reply to message #209208] Fri, 15 December 2006 15:53 Go to previous messageGo to next message
andrew again
Messages: 2577
Registered: March 2000
Senior Member
You need to make sure you can call the oracle proc first from your browser using http://<my server>:<port>/pls/mydad/myproc?param1=1234

If you can do that - then your question becomes a VBA issue of how to call the external URL. One way to work around the login issue is to do a check in myproc to see where the request is coming from and if it's the VBA app, then bypass the login requirement. If myproc needs to detect who the calling user is - then you do need to log into Oracle first. Common ways to keep the user logged in are to set a cookie or maintain a session table which identifies the returning user by their IP address (you don't want to pick up the IP of the host running the VBA app).
Re: VBA and mod_plsql [message #209753 is a reply to message #209602] Sun, 17 December 2006 10:10 Go to previous messageGo to next message
sparrow
Messages: 8
Registered: November 2006
Junior Member
Excellent, thanks for that.

Do you have any pointers on creating a cookie in Excel?

Edit: Meant to say that I do need to validate the user, hence the cookie question.

[Updated on: Sun, 17 December 2006 13:43]

Report message to a moderator

Re: VBA and mod_plsql [message #209826 is a reply to message #209753] Mon, 18 December 2006 00:52 Go to previous messageGo to next message
andrew again
Messages: 2577
Registered: March 2000
Senior Member
As far as I know cookies are only a browser thing. You'll have to consider a session table and track users by IP address. Note that this usually won't work for users over a VPN because they may all show as the same IP address.
Re: VBA and mod_plsql [message #209854 is a reply to message #209208] Mon, 18 December 2006 03:11 Go to previous messageGo to next message
sparrow
Messages: 8
Registered: November 2006
Junior Member
Thanks for your help. I know I've read somewhere that it's possible to use cookies in Excel (although that may be a bit misleading as it's probably using http stuff to do it), so I'll keep looking.
Re: VBA and mod_plsql [message #218496 is a reply to message #209854] Thu, 08 February 2007 07:56 Go to previous message
tkstock
Messages: 28
Registered: April 2006
Location: Richmond
Junior Member
Why do you want to use a cookie in Excel? The only reason to use a cookie is to store information on the client side that will persist between HTTP requests - you can store information in VBA variables! No need to have a cookie on the client.
Previous Topic: Remember a variable when reloading a website
Next Topic: Browser Back Button problem
Goto Forum:
  


Current Time: Mon Dec 05 07:09:48 CST 2016

Total time taken to generate the page: 0.05450 seconds