Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ SQL » Trouble Adding rows to SqlArray
Trouble Adding rows to SqlArray [message #20257] Thu, 05 March 2009 15:38 Go to previous message
bianconejo is currently offline  bianconejo
Messages: 11
Registered: March 2009
Promising Member
Hi Guys,

First of all I'd like to thank you and underline your talent for this great environnement.

I'm using Upp for 1 month now and I like the way it is structured.

I've studied HomeBudget, PostgreSQL example and SQLCommander.

I'd like to know how to add a new row to a sqlarray linked to a form (via array.addctrl).

I've tried several methods like DoAppend, Add and SQL insert query, but when I refresh the array, the new data are missing.

Thanx for your reply and keep up the good work!

the table I attempt to add data to:
TABLE_(ORGANISATION)
   SERIAL_  (ORGANISATION_ID) PRIMARY_KEY
   STRING_  (ORGANISATION_NOM, 200) INDEX
   INT64_  	(ORGANISATION_TYPE) REFERENCES(TYPE_ORGANISATION.TYPE_ORGANISATION_ID)
   INT64_  	(ORGANISATION_PREFIXE) REFERENCES(PREFIXE_ORGANISATION.PREFIXE_ORGANISATION_ID)
   STRING_  (ORGANISATION_OBS, 200)
END_TABLE


the definition of the array links:
a_cache.SetSession(m_session);
[..]
	
a_cache.SetTable(ORGANISATION);
a_cache.AddKey(ORGANISATION_ID);
a_cache.AddColumn(ORGANISATION_NOM, "Entreprise");
a_cache.AddColumn(ORGANISATION_TYPE, "Type");
a_cache.AddColumn(ORGANISATION_PREFIXE, "PREFIXE");
a_cache.AddColumn(ORGANISATION_OBS, "Obs");
a_cache.SetOrderBy(ORGANISATION_ID);
	
a_cache.AddCtrl(ORGANISATION_NOM,e_entreprise);
a_cache.AddCtrl(ORGANISATION_TYPE,d_Type);
a_cache.AddCtrl(ORGANISATION_PREFIXE,d_Prefixe);
a_cache.AddCtrl(ORGANISATION_OBS,e_Obs);
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Compacting an MS-Access db
Next Topic: PostgreSQL example does not save data to database
Goto Forum:
  


Current Time: Sun Apr 28 14:29:11 CEST 2024

Total time taken to generate the page: 0.94576 seconds