Virtual strings in DBF

Post Reply
Natter
Posts: 1241
Joined: Mon May 14, 2007 9:49 am

Virtual strings in DBF

Post by Natter »

Is it possible to work with virtual (not physical) strings in DBF ?
User avatar
Antonio Linares
Site Admin
Posts: 42512
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Has thanked: 31 times
Been thanked: 73 times
Contact:

Re: Virtual strings in DBF

Post by Antonio Linares »

Dear Yuri,

What is a virtual string ?
regards, saludos

Antonio Linares
www.fivetechsoft.com
Natter
Posts: 1241
Joined: Mon May 14, 2007 9:49 am

Re: Virtual strings in DBF

Post by Natter »

Something like that:
In the open DBF (In exclusive mode), we add lines, but do not save them to disk.
These lines exist only while the database is open.
User avatar
Carles
Posts: 1149
Joined: Fri Feb 10, 2006 2:34 pm
Location: Barcelona
Been thanked: 7 times
Contact:

Re: Virtual strings in DBF

Post by Carles »

Natter,

Prueba de usar el rddarray

C.
Salutacions, saludos, regards

"...programar es fácil, hacer programas es difícil..."

UT Page -> https://carles9000.github.io/
Forum UT -> https://discord.gg/bq8a9yGMWh
Skype -> https://join.skype.com/cnzQg3Kr1dnk
Natter
Posts: 1241
Joined: Mon May 14, 2007 9:49 am

Re: Virtual strings in DBF

Post by Natter »

Thanks for the advice. Is it possible to learn more about using RddArray ?
User avatar
Carles
Posts: 1149
Joined: Fri Feb 10, 2006 2:34 pm
Location: Barcelona
Been thanked: 7 times
Contact:

Re: Virtual strings in DBF

Post by Carles »

Salutacions, saludos, regards

"...programar es fácil, hacer programas es difícil..."

UT Page -> https://carles9000.github.io/
Forum UT -> https://discord.gg/bq8a9yGMWh
Skype -> https://join.skype.com/cnzQg3Kr1dnk
Natter
Posts: 1241
Joined: Mon May 14, 2007 9:49 am

Re: Virtual strings in DBF

Post by Natter »

If I understood correctly, then we are talking about creating a DBF in memory and working with it.
If so, then this is not exactly what I need. I need to open an existing DBF on disk (which already has some strings) and
add virtual strings to it. I.e., the physical strings of this DBF will be available to everyone, and the virtual ones only to me.
User avatar
Carles
Posts: 1149
Joined: Fri Feb 10, 2006 2:34 pm
Location: Barcelona
Been thanked: 7 times
Contact:

Re: Virtual strings in DBF

Post by Carles »

Then u could use triggers with rdd. Every time update a field then it will update a dbf tmp with the same struct.

C.
Salutacions, saludos, regards

"...programar es fácil, hacer programas es difícil..."

UT Page -> https://carles9000.github.io/
Forum UT -> https://discord.gg/bq8a9yGMWh
Skype -> https://join.skype.com/cnzQg3Kr1dnk
User avatar
Carles
Posts: 1149
Joined: Fri Feb 10, 2006 2:34 pm
Location: Barcelona
Been thanked: 7 times
Contact:

Re: Virtual strings in DBF

Post by Carles »

And before ask me, here example of use it

https://github.com/harbour/core/blob/ma ... logrdd.prg

C.
Salutacions, saludos, regards

"...programar es fácil, hacer programas es difícil..."

UT Page -> https://carles9000.github.io/
Forum UT -> https://discord.gg/bq8a9yGMWh
Skype -> https://join.skype.com/cnzQg3Kr1dnk
User avatar
Jimmy
Posts: 1740
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany
Has thanked: 2 times

Re: Virtual strings in DBF

Post by Jimmy »

hi Natter.

what about "GhostRec" :idea:
greeting,
Jimmy
Natter
Posts: 1241
Joined: Mon May 14, 2007 9:49 am

Re: Virtual strings in DBF

Post by Natter »

What is this ?
User avatar
Jimmy
Posts: 1740
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany
Has thanked: 2 times

Re: Virtual strings in DBF

Post by Jimmy »

hi Natter,

"GhostRec" -> EOF() + 1
greeting,
Jimmy
Natter
Posts: 1241
Joined: Mon May 14, 2007 9:49 am

Re: Virtual strings in DBF

Post by Natter »

Thank you, Jimmy, Interesting idea !
Post Reply