1. RE: Include Database.e
Hi Serge,
Welcome to Euphoria! May I suggest the obvious first step when working
with anything unfamiliar... Read The Manual!
Here's what's wrong with your program...
1. Euphoria is case sensitive. "include" (all lowercase) is a special
top-level statement. "Include" (with capital 'I') is interpreted as an
undeclared object or constant and this explains your error message.
2. Once you fix that, you'll get a similar error about i1 not being
declared. In Euphoria, all variables must be declared before
assignment.
3. Read the documentation on the Euphoria Database System for proper
usage of the function db_open().
Here is a simple example of what you might be attempting to do:
-----------------------------
include database.e
integer i1
i1 = db_open("MYDATA.EDB",DB_LOCK_EXCLUSIVE)
-----------------------------
Once you've read the docs and understand the basics of programming in
Euphoria please to come back with further questions. Everybody here is
always happy to help.
Regards,
-- Brian
jondolar wrote:
>
>
> Hi everyone
> I'm new to Euphoria. I'm simply trying to open an eu.edb by running the
> following code in the Ed:
>
> Include database.e
> i1 = db_open(s, i2) MYDATA.EDB
>
> I get the following error message...Include has not been declared...
>
> Why? Whats wrong
> Can any one help before i start chewing my desk?
> TIA
> Serge Lavigne
>
2. RE: Include Database.e
Thanks Brian. Your help is appreciated. I did read the doc but there is
so much material. I'm an older guy (63) and memory is not what it used
to be ;) I'm particularly interested in databases. What do you think of
the Tsunami engine being accessible from Euphoria now?
Brian Broker wrote:
>
>
> Hi Serge,
>
> Welcome to Euphoria! May I suggest the obvious first step when working
> with anything unfamiliar... Read The Manual!
>
> Here's what's wrong with your program...
>
> 1. Euphoria is case sensitive. "include" (all lowercase) is a special
> top-level statement. "Include" (with capital 'I') is interpreted as an
> undeclared object or constant and this explains your error message.
>
> 2. Once you fix that, you'll get a similar error about i1 not being
> declared. In Euphoria, all variables must be declared before
> assignment.
>
> 3. Read the documentation on the Euphoria Database System for proper
> usage of the function db_open().
>
> Here is a simple example of what you might be attempting to do:
> -----------------------------
> include database.e
>
> integer i1
>
> i1 = db_open("MYDATA.EDB",DB_LOCK_EXCLUSIVE)
> -----------------------------
>
> Once you've read the docs and understand the basics of programming in
> Euphoria please to come back with further questions. Everybody here is
> always happy to help.
>
> Regards,
> -- Brian
>
>
> jondolar wrote:
> >
> >
> > Hi everyone
> > I'm new to Euphoria. I'm simply trying to open an eu.edb by running the
> > following code in the Ed:
> >
> > Include database.e
> > i1 = db_open(s, i2) MYDATA.EDB
> >
> > I get the following error message...Include has not been declared...
> >
> > Why? Whats wrong
> > Can any one help before i start chewing my desk?
> > TIA
> > Serge Lavigne
> >
>
3. RE: Include Database.e
Well, the RefMan puts it this way:
2.4.1 Identifiers
Identifiers, which consist of variable names and other user-defined
symbols, may be of any length. Upper and lower case are distinct.
Does this make more sense to non-programmer-types? I dunno... Maybe an
example should be included? Like:
object A, a -- declares two distinct variables
I'm not much of a street rapper so I'm no help there...
-- Brian
Kat wrote:
>
>
> On 2 Jul 2003, at 17:20, 1evan at sbcglobal.net wrote:
>
> >
> > Try include instead of Include. Euphoria is case sensitive.
>
> It has crossed my mind many times that maybe non-programmer-type
> people do not understand "case sensitive", after all, there is no hint
> about
> upper case vs lower case in the dictionary i just looked it up in. Maybe
> this
> should be spelled out in street language, maybe set to rap music?
>
> Kat
>
4. RE: Include Database.e
About the "Include" vs "include" error:
Using an editor that does color coding would catch errors of that kind
instantly.
Jerry Story
5. RE: Include Database.e
- Posted by gertie at visionsix.com
Jul 03, 2003
On 2 Jul 2003, at 22:41, Brian Broker wrote:
>
>
> Well, the RefMan puts it this way:
>
> 2.4.1 Identifiers
>
> Identifiers, which consist of variable names and other user-defined
> symbols, may be of any length. Upper and lower case are distinct.
>
> Does this make more sense to non-programmer-types? I dunno... Maybe an
> example should be included? Like:
>
> object A, a -- declares two distinct variables
>
> I'm not much of a street rapper so I'm no help there...
Perhaps the BASS lib in the user contributions would help you.
Kat
> -- Brian
>
> Kat wrote:
> >
> >
> > On 2 Jul 2003, at 17:20, 1evan at sbcglobal.net wrote:
> >
> > >
> > > Try include instead of Include. Euphoria is case sensitive.
> >
> > It has crossed my mind many times that maybe non-programmer-type
> > people do not understand "case sensitive", after all, there is no hint
> > about
> > upper case vs lower case in the dictionary i just looked it up in. Maybe
> > this
> > should be spelled out in street language, maybe set to rap music?
> >
> > Kat
> >
>
>
>
> TOPICA - Start your own email discussion group. FREE!
>
>