Real Software Forums

The forum for Real Studio and other Real Software products.
[ REAL Software Website | Board Index ]
It is currently Fri May 25, 2018 5:30 pm
xojo

All times are UTC - 5 hours




Post new topic Reply to topic  [ 7 posts ] 
Author Message
 Post subject: Saving a lot of form data
PostPosted: Tue Mar 26, 2013 2:36 pm 
Offline

Joined: Fri Dec 16, 2005 9:26 am
Posts: 121
Hi,

for a new customer web project we have to save lots of data from web forms.
I mean really lots of form fields. Maybe some thousands placed over many forms.

Until now we always save data into databases (mysql, sqlite, valentina) with fields for each form element.
But I think this could make me lots of headache with this project.

I thought about using a document oriented database like mongodb or couchdb for this but as I see this is not possible with real studio.
Another idea could be to save just xml documents out of dictionaries.

Has somebody done a similar thing before and has some tipps for me how to save this data?

Best regards

Fabian


Top
 Profile  
Reply with quote  
 Post subject: Re: Saving a lot of form data
PostPosted: Tue Mar 26, 2013 3:05 pm 
Offline

Joined: Fri Nov 16, 2007 10:18 pm
Posts: 195
Location: Portland, OR
fabian wrote:
I thought about using a document oriented database like mongodb or couchdb for this but as I see this is not possible with real studio.

Why not? Just look at the docs for JSONItem.

http://docs.realsoftware.com/index.php/JSONItem

Then use an HTTPSocket with your new knowledge and go here:

http://wiki.apache.org/couchdb/CouchIn15Minutes

It really is quite easy.

_________________
Windows: Win7 64bit sp1, Vista 32bit sp2, WinXP 32bit SP3
Linux: RH EL6
Mac: Died in 2011 and took 2 months to notice.

RealStudio: 2012r2


Top
 Profile  
Reply with quote  
 Post subject: Re: Saving a lot of form data
PostPosted: Tue Mar 26, 2013 6:00 pm 
Offline
User avatar

Joined: Sat Nov 28, 2009 3:12 am
Posts: 102
Hi Fabian,

prove me please that any doc oriented DB can be better of Valentina.

I think many people already have understand traps of this "new wave", which in fact repeat on new loop pre-relational models and their troubles.
Relational DBs already have live through wave of OO dbs in 1995-2000, which was going kill all relational,
then was wave of "XML databases", which also was going replace anything else ...
then happened next wave -- wow non-SQL wave ...

_________________
Best regards,

Ruslan Zasukhin
VP Engineering and New Technology
Paradigma Software, Inc

Valentina Server, Valentina for REALbasic, Valentina Reports, ...
http://www.paradigmasoft.com


Top
 Profile  
Reply with quote  
 Post subject: Re: Saving a lot of form data
PostPosted: Tue Mar 26, 2013 6:05 pm 
Offline
User avatar

Joined: Sat Nov 28, 2009 3:12 am
Posts: 102
fabian wrote:
for a new customer web project we have to save lots of data from web forms.
I mean really lots of form fields. Maybe some thousands placed over many forms.

Until now we always save data into databases (mysql, sqlite, valentina) with fields for each form element.
But I think this could make me lots of headache with this project.

I thought about using a document oriented database like mongodb or couchdb for this but as I see this is not possible with real studio.
Another idea could be to save just xml documents out of dictionaries.

Has somebody done a similar thing before and has some tipps for me how to save this data?


So you going produce from N fields of a form => XML text document. okay.
And save into disk folder?

How this is better of save just into TEXT Field of DB ?

It sounds you not going do any searches by fields of this forms.Just save. Later may be read back.
yes?

_________________
Best regards,

Ruslan Zasukhin
VP Engineering and New Technology
Paradigma Software, Inc

Valentina Server, Valentina for REALbasic, Valentina Reports, ...
http://www.paradigmasoft.com


Top
 Profile  
Reply with quote  
 Post subject: Re: Saving a lot of form data
PostPosted: Tue Mar 26, 2013 6:07 pm 
Offline
User avatar

Joined: Sat Nov 28, 2009 3:12 am
Posts: 102
also do not forget about "vertical" solution.

this is why you use not 1000 fields in table, than more of this number is not fixed,
but you define 2 tables

a) first have 1000 or so records -- definitions

1 field1
2 field2

b) the second table have a lots records, with PTRs to the first table. Of course much more job for DB comparing to just save single record with XML ...
But this is if you want be able do searches by that fields.

_________________
Best regards,

Ruslan Zasukhin
VP Engineering and New Technology
Paradigma Software, Inc

Valentina Server, Valentina for REALbasic, Valentina Reports, ...
http://www.paradigmasoft.com


Top
 Profile  
Reply with quote  
 Post subject: Re: Saving a lot of form data
PostPosted: Wed Mar 27, 2013 1:58 am 
Offline

Joined: Fri Dec 16, 2005 9:26 am
Posts: 121
Hi Bob, hi Ruslan,

thanks for your replies.
Yes, I don't have to search or work with the data. Its just save and load from the web app. Some calculation is done inside the app.
So I am looking for a way to easily save without having to plan and create database structure.
Saving xml from dictionary into a database field is also an good option.

Best regards

Fabian


Top
 Profile  
Reply with quote  
 Post subject: Re: Saving a lot of form data
PostPosted: Wed Mar 27, 2013 5:08 am 
Offline
User avatar

Joined: Sat Nov 28, 2009 3:12 am
Posts: 102
fabian wrote:
Hi Bob, hi Ruslan,

thanks for your replies.
Yes, I don't have to search or work with the data. Its just save and load from the web app. Some calculation is done inside the app.
So I am looking for a way to easily save without having to plan and create database structure.
Saving xml from dictionary into a database field is also an good option.

Best regards

Fabian


Then I think even better not touch XML, because its parsing is slower.
you can just join your data according to some special rules, which YOU invent, to be able later split them back in fastest way.

for example:
1,5,8,fabian,best of all, ...
or
1,5,8,'fabian','best of all', ...
or
1//5//8//fabian//best of all//...

i.e. choose if possible good delimiter...

Although if you have variable number of fields ... then XML yes is required. You need tags
but still can be invented something more fast, if not required human-readable format

e.g. use numbers as tags,
1/2/3 means Name, Last Name, Address

and save TWO parts in TWO fields: first keeps list of such numeric tags, second keeps list of corresponded values.

_________________
Best regards,

Ruslan Zasukhin
VP Engineering and New Technology
Paradigma Software, Inc

Valentina Server, Valentina for REALbasic, Valentina Reports, ...
http://www.paradigmasoft.com


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 

All times are UTC - 5 hours


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group