Patch level : 10.0
Files correlati : lv?.exe Ricompilazione Demo : [ ] Commento : Corretta getione cache su tabelle di modulo git-svn-id: svn://10.65.10.50/trunk@17250 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
ee73967709
commit
dc756c6efb
@ -795,27 +795,29 @@ TRecord_cache& TDB_cache::rec_cache(int file)
|
|||||||
int TDB_cache::build_table_key(const char* table, const char* key, TToken_string& k) const
|
int TDB_cache::build_table_key(const char* table, const char* key, TToken_string& k) const
|
||||||
{
|
{
|
||||||
CHECK(table && *table, "Invalid Table code");
|
CHECK(table && *table, "Invalid Table code");
|
||||||
|
TString16 tablename = table; // Attenzione posso avere tabelle di modulo come &PC000883BAR
|
||||||
int file = LF_TAB;
|
int file = LF_TAB;
|
||||||
k.cut(0);
|
k.cut(0);
|
||||||
if (!isalnum(*table)) // gestisco i casi come %IVA e &AUT
|
if (!isalnum(*table)) // gestisco i casi come %IVA e &AUT
|
||||||
{
|
{
|
||||||
|
tablename.ltrim(1); // toglie carattere speciale
|
||||||
switch (*table)
|
switch (*table)
|
||||||
{
|
{
|
||||||
case '%': file = LF_TABCOM; table++; break;
|
case '%': file = LF_TABCOM; break;
|
||||||
case '^': file = LF_TABGEN; table++; break;
|
case '^': file = LF_TABGEN; break;
|
||||||
case '&': file = LF_TABMOD;
|
case '&': file = LF_TABMOD;
|
||||||
{
|
{
|
||||||
const TModule_table mt(table);
|
const TModule_table mt(table);
|
||||||
k = mt.module();
|
k = mt.module();
|
||||||
k.add(mt.customer());
|
k.add(mt.customer());
|
||||||
table = mt.name();
|
tablename = mt.name();
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case '$':
|
case '$':
|
||||||
default : file = LF_TAB; table++; break;
|
default : file = LF_TAB; break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
k.add(table);
|
k.add(tablename);
|
||||||
k.add(key);
|
k.add(key);
|
||||||
return file;
|
return file;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user