|
Home > Archive > dBASE Web Applications > April 2006 > crazy error
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
|
|
| Dan Anderson 2006-04-04, 11:24 am |
| db+ I am having problems with code that will run from the command prompt
but not from inside an executable. Here is a code sample cut and pasted
from the cursed file. The offending code is "e.active = true". If I enter
it command by command from the command prompt it has no problem and lets me
inspect the .dbf in that alias. The error message is:
Error: Unknown database name: losses
set proc to WebClassEx.cc additive
oCGI = new CGISessionEx()
oCGI.Connect()
LOCAL cSeek, cAgent, cProducer
cAgent = oCGI["REC"]
cProducer = oCGI["UserID"]
e= new DATABASE()
e.databasename = "losses"
e.active = true
qUser1 = new QUERY()
qUser1.database = e
qUser1.sql = "SELECT * from LossRuns.dbf"
qUser1.active = true
Can anyone help with this?
--
Dan Anderson
UBI Processing Dept.
andersond@ubinc.com
800-444-4824 ext 101
| |
| Claus Mygind 2006-04-04, 11:24 am |
| Almost sounds like your web server does not have access to the same data
base that your db+ has. Have you checked the BDE adminstrator for the
webserver?
"Dan Anderson" <andersond@ubinc.com> wrote in message
news:JLmMav$VGHA.448@news-server...
> db+ I am having problems with code that will run from the command prompt
> but not from inside an executable. Here is a code sample cut and pasted
> from the cursed file. The offending code is "e.active = true". If I
> enter it command by command from the command prompt it has no problem and
> lets me inspect the .dbf in that alias. The error message is:
>
> Error: Unknown database name: losses
>
> set proc to WebClassEx.cc additive
> oCGI = new CGISessionEx()
> oCGI.Connect()
>
> LOCAL cSeek, cAgent, cProducer
> cAgent = oCGI["REC"]
> cProducer = oCGI["UserID"]
>
> e= new DATABASE()
> e.databasename = "losses"
> e.active = true
>
> qUser1 = new QUERY()
> qUser1.database = e
> qUser1.sql = "SELECT * from LossRuns.dbf"
> qUser1.active = true
>
>
> Can anyone help with this?
>
>
> --
> Dan Anderson
> UBI Processing Dept.
> andersond@ubinc.com
> 800-444-4824 ext 101
>
| |
| Dan Anderson 2006-04-05, 9:24 am |
| You intuition was exactly correct. Once I added the alias to the webserver
I had access to the file. But, of course, I'm stumped again. It now throws
the following error:
Cannot access file: K:\Loss Runs\lossruns.dbf
That is the correct path; so, it is interpreting the database alias
correctly. And, again, it works flawlessly from the command line.
e= new DATABASE()
e.databasename = "losses"
e.active = true
qlossruns1 = new QUERY()
qlossruns1.database = e
qlossruns1.sql = 'SELECT * from "lossruns.dbf"'
qlossruns1.active = true
// populate record with data from array
oCGI. loadFieldsFromArray(
qlossruns1.rowset.fields, true)
--
Dan Anderson
UBI Processing Dept.
andersond@ubinc.com
800-444-4824 ext 101
"Claus Mygind" <cmygind@tsccorp.com> wrote in message
news:akqErDAWGHA.448@news-server...
> Almost sounds like your web server does not have access to the same data
> base that your db+ has. Have you checked the BDE adminstrator for the
> webserver?
>
>
>
> "Dan Anderson" <andersond@ubinc.com> wrote in message
> news:JLmMav$VGHA.448@news-server...
>
>
| |
|
| HI,
Make sure youre web server has the needed rights to that folder and file
Robert
"Dan Anderson" <andersond@ubinc.com> wrote in message
news:bI1Vw6IWGHA.1548@news-server...
> You intuition was exactly correct. Once I added the alias to the
webserver
> I had access to the file. But, of course, I'm stumped again. It now
throws
> the following error:
>
> Cannot access file: K:\Loss Runs\lossruns.dbf
>
> That is the correct path; so, it is interpreting the database alias
> correctly. And, again, it works flawlessly from the command line.
>
>
> e= new DATABASE()
> e.databasename = "losses"
> e.active = true
>
> qlossruns1 = new QUERY()
> qlossruns1.database = e
> qlossruns1.sql = 'SELECT * from "lossruns.dbf"'
> qlossruns1.active = true
>
>
> // populate record with data from array
> oCGI. loadFieldsFromArray(
qlossruns1.rowset.fields, true)
>
> --
> Dan Anderson
> UBI Processing Dept.
> andersond@ubinc.com
> 800-444-4824 ext 101
> "Claus Mygind" <cmygind@tsccorp.com> wrote in message
> news:akqErDAWGHA.448@news-server...
prompt[color=darkred
]
pasted[color=darkred
]
and[color=darkred]
>
>
| |
| Dan Anderson 2006-04-05, 9:24 am |
| Good suggestion. I'll check that.
--
Dan Anderson
UBI Processing Dept.
andersond@ubinc.com
800-444-4824 ext 101
"rb" <me@u.com> wrote in message news:M$wmVGLWGHA.1176@news-server...
> HI,
>
> Make sure youre web server has the needed rights to that folder and file
>
> Robert
>
> "Dan Anderson" <andersond@ubinc.com> wrote in message
> news:bI1Vw6IWGHA.1548@news-server...
> webserver
> throws
> prompt
> pasted
> and
>
>
| |
| Claus Mygind 2006-04-06, 1:24 pm |
| If all else fails try renaming your folder and remove the blank space.
"Dan Anderson" <andersond@ubinc.com> wrote in message
news:bI1Vw6IWGHA.1548@news-server...
> You intuition was exactly correct. Once I added the alias to the
> webserver I had access to the file. But, of course, I'm stumped again.
> It now throws the following error:
>
> Cannot access file: K:\Loss Runs\lossruns.dbf
>
> That is the correct path; so, it is interpreting the database alias
> correctly. And, again, it works flawlessly from the command line.
>
>
> e= new DATABASE()
> e.databasename = "losses"
> e.active = true
>
> qlossruns1 = new QUERY()
> qlossruns1.database = e
> qlossruns1.sql = 'SELECT * from "lossruns.dbf"'
> qlossruns1.active = true
>
>
> // populate record with data from array
> oCGI. loadFieldsFromArray(
qlossruns1.rowset.fields, true)
>
> --
> Dan Anderson
> UBI Processing Dept.
> andersond@ubinc.com
> 800-444-4824 ext 101
> "Claus Mygind" <cmygind@tsccorp.com> wrote in message
> news:akqErDAWGHA.448@news-server...
>
>
|
|
|
|
|