1. Field's DataBases
- Posted by Sergio Gelli <sergelli at uol.com.br> Nov 24, 2001
- 369 views
Hi Folks. Bom dia para todos. ( Good day for all ) You just know about my English, so please, stay patience. I am trying to made a DataBase. The first program creates and are the modifier of all DataBases structures. He handles names, types and sizes of all DataBase's fields. No probles in this step. Another program will open everyone DataBase if he is created with the above refer program. After it, i can read field's names inside the opened DataBase, like this: name_first_field = line_config_database[1..10] or read type's fields as type_second_field = line_config_database[...and so go. The problem is: I want use this field's name like as any variables, but i don't know how declare it and Euphoria don't works with pointers like "C" I believe you will understand better in down lines. If i know how variables the program will works,it is easy, just declare it like as: sequence NAME -- no problems But the program was running and in any moment it receives a information that it will need works with a new variable type sequence named "NAME" and in the next lines, I would to do anything like this NAME = "Sergio Gelli" But the variable "NAME" isn't was declared because this program only know about its when opens the DataBases. How can i do it? Exists another format to do it? I will stay gratefully for any suggestions. Muito obrigado pela sua atencao. ( Very thanks to your attention ) Udachi to Igor ( Spell I ok ?) ( sorry i only know this, send more) Sergio Gelli Jundiai SP Brasil
2. Re: Field's DataBases
- Posted by Travis Beaty <travis_beaty at yahoo.com> Nov 24, 2001
- 369 views
Hello Sergio! Okay, I *think* I know what you are talking about here. You are basically wanting to store a variable name, and its value in the database file. This can be done with Euphoria ... sort of. Make one sequence, say sVars, for instance. In sVars, you will need elements with the following format: {Variable Name, Value} Here's some very untested code: sequence sVars procedure addVariable(sequence sVariableName, object xValue) sVars & {sVariableName, xValue} end procedure function getValue(sequence sVariableName) if not length(sVars) then puts(1, "Oops. No variables declared.\n") return end if for i 1 to length(sVars) do if equal(sVariableName, sVars[i][1]) then return sVars[i][2] end if end for puts(1, "Couldn't find that variable. Sorry.\n") return 0 end function Hope this helps you out some. I'm having to do the same thing in the Euphoria Package compiler for user defined variables declared in EPC makefiles. Travis Beaty Evans, Colorado. -------Original Message------- From: EUforum at topica.com Date: Saturday, November 24, 2001 02:34:20 PM To: EUforum Subject: Field's DataBases ====== The Euphoria Mailing List ====== Hi Folks. Bom dia para todos. ( Good day for all ) You just know about my English, so please, stay patience. I am trying to made a DataBase. The first program creates and are the modifier of all DataBases structures. He handles names, types and sizes of all DataBase's fields. No probles in this step. Another program will open everyone DataBase if he is created with the above refer program. After it, i can read field's names inside the opened DataBase, like this: name_first_field line_config_database[1..10] or read type's fields as type_second_field line_config_database[...and so go. The problem is: I want use this field's name like as any variables, but i don't know how declare it and Euphoria don't works with pointers like "C" I believe you will understand better in down lines. If i know how variables the program will works,it is easy, just declare it like as: sequence NAME -- no problems But the program was running and in any moment it receives a information that it will need works with a new variable type sequence named "NAME" and in the next lines, I would to do anything like this NAME "Sergio Gelli" But the variable "NAME" isn't was declared because this program only know about its when opens the DataBases. How can i do it? Exists another format to do it? I will stay gratefully for any suggestions. Muito obrigado pela sua atencao. ( Very thanks to your attention ) Udachi to Igor ( Spell I ok ?) ( sorry i only know this, send more) Sergio Gelli Jundiai SP Brasil =^================================ This email was sent to: travis_beaty at yahoo.com
3. Re: Field's DataBases
- Posted by Travis Beaty <travis_beaty at yahoo.com> Nov 24, 2001
- 373 views
Dang! Sorry about the **unformatted**, untested code. Getting used to my new email program, and it seems to have screwed up. Travis Beaty Evans, Colorado.
4. Re: Field's DataBases
- Posted by Igor Kachan <kinz at peterlink.ru> Nov 25, 2001
- 378 views
Dobryj den', Sergio ! (Good day Sergio !) ---------- > ïÔ: Sergio Gelli <sergelli at uol.com.br> > ëÏÍÕ: EUforum <EUforum at topica.com> > ôÅÍÁ: RE: Field's DataBases > äÁÔÁ: Sunday, November 25, 2001 05:19 > Or how substitute a line program using > commands into a one variable?? In Eu, there is no the straight way to save the Eu *native* program code into the string and then to load and execute it on the fly. (You ask about the string execution, yes ?). But somewhat similar is possible with a *machine code*, which you can place into the sequence (same as save) and then execute after poke() with call() (same as load and run). This trick is very very rare thing here. Maybe more simple way is to save new native Eu program code in the file.e and then just use system_exec() to run this file.e with another copy of Eu interpreter. New machines have just large memory for such an aerobatics. S uvazheniem, (Regards) Igor Kachan. kinz at peterlink.ru P.S. 'zh' sounds as J in the word 'Jundiai'. I think, I do not know exactly, or almost as j in my favourite English 'just' word without the first like 'd' sound. 'j' sounds as 'y' in 'May' word. 'y' sounds almost as 'y' in 'system' word. n' is very soft n. Boney M sing - Crazy Russian, no ?
5. Re: Field's DataBases
- Posted by Martin Stachon <martin.stachon at worldonline.cz> Nov 26, 2001
- 364 views
Hi Igor, > S uvazheniem, > (Regards) > Igor Kachan. > kinz at peterlink.ru > P.S. 'zh' sounds as J in the word 'Jundiai'. > I think, I do not know exactly, or almost as j > in my favourite English 'just' word > without the first like 'd' sound. > 'j' sounds as 'y' in 'May' word. > 'y' sounds almost as 'y' in 'system' word. > n' is very soft n. > > Boney M sing - Crazy Russian, no ? I can read and quite understant Russian, if it is written in latinic. (Pan-Slavic understanding However, I can't read Azbuka characters. Is there a tool for translating Azbuka -> latinic ? S pozdravy, (Greetings,) Martin
6. Re: Field's DataBases
- Posted by Igor Kachan <kinz at peterlink.ru> Nov 26, 2001
- 357 views
Hi Martin, ---------- > ïÔ: Martin Stachon <martin.stachon at worldonline.cz> > ëÏÍÕ: EUforum <EUforum at topica.com> > ôÅÍÁ: Re: Field's DataBases > äÁÔÁ: Sunday, November 25, 2001 20:38 > > Hi Igor, > > S uvazheniem, > > (Regards) > > Igor Kachan. > > kinz at peterlink.ru > > P.S. 'zh' sounds as J in the word 'Jundiai'. > > I think, I do not know exactly, or almost as j > > in my favourite English 'just' word > > without the first like 'd' sound. > > 'j' sounds as 'y' in 'May' word. > > 'y' sounds almost as 'y' in 'system' word. > > n' is very soft n. > > > > Boney M sing - Crazy Russian, no ? > > I can read and quite understant Russian, if > it is written in latinic. (Pan-Slavic understanding > However, I can't read Azbuka characters. Is there a tool > for translating Azbuka -> latinic ? > > S pozdravy, > (Greetings,) > Martin Such a tool must be different for the different latinic languages to have a good practical transcription (rules of pronunciation). I have two tables for this transcription (by AS USSR and by ISO) in my The Linguistic Encyclopedic Dictionary. These tables are somewhat *classic* for *international* typography, not for computers. And there are *local* rules for this transcription in different countries, first of all, for the correct transliteration of Russian names with the latinic letters. Tomorrow, I'll prepare these *classic* tables as .bmp with my polyglot editor and post it to you. Then you'll can make that tool for youself, if you want, with your native puter's code pages. You'll can see that really 'zh' above is not 'zh', but just 'z' with one of diacritics. Vsego horoshego ! (All good for you !) Regards, Igor Kachan kinz at peterlink.ru