|
|
Home » U++ Library support » U++ SQL » Trouble Adding rows to SqlArray
Trouble Adding rows to SqlArray [message #20257] |
Thu, 05 March 2009 15:38  |
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);
|
|
|
|
|
|
|
|
|
|
Goto Forum:
Current Time: Sun Apr 27 00:27:28 CEST 2025
Total time taken to generate the page: 0.00981 seconds
|
|
|