Patch level : 12.0 no-patch
Files correlati : tsdb Commento : aggiunto rtrim in get
This commit is contained in:
parent
658cd4098c
commit
82b0e636b2
@ -11,3 +11,22 @@ const TDate SSimple_query::sq_get_date(const char * field)
|
|||||||
const TDate app(_rec.get_date(field));
|
const TDate app(_rec.get_date(field));
|
||||||
return app;
|
return app;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
TString SSimple_query::sq_get(const char* field, bool rtrim)
|
||||||
|
{
|
||||||
|
TString fld = _rec.get(field);
|
||||||
|
if (rtrim)
|
||||||
|
fld.rtrim();
|
||||||
|
|
||||||
|
return fld;
|
||||||
|
}
|
||||||
|
|
||||||
|
TString SSimple_query::sq_get(string field, bool rtrim)
|
||||||
|
{
|
||||||
|
return sq_get(field.c_str(), rtrim);
|
||||||
|
}
|
||||||
|
|
||||||
|
TString SSimple_query::sq_get(TString& field, bool rtrim)
|
||||||
|
{
|
||||||
|
return sq_get(static_cast<const char*>(field), rtrim);
|
||||||
|
}
|
||||||
|
@ -166,11 +166,11 @@ public:
|
|||||||
/**< Ritorna il valore nel campo (field) in formato (SADateTime), Campo non gestisce le ore */
|
/**< Ritorna il valore nel campo (field) in formato (SADateTime), Campo non gestisce le ore */
|
||||||
//SADateTime sqGetDateTime(const char* field) { get_short(field); }
|
//SADateTime sqGetDateTime(const char* field) { get_short(field); }
|
||||||
/**< Ritorna il valore nel campo (field) passato come (const char *) in formato (const char *) */
|
/**< Ritorna il valore nel campo (field) passato come (const char *) in formato (const char *) */
|
||||||
const char* sq_get(const char* field) { return _rec.get(field); }
|
TString sq_get(const char* field, bool rtrim = true);
|
||||||
/**< Ritorna il valore nel campo (field) passato come (string) in formato (const char *) */
|
/**< Ritorna il valore nel campo (field) passato come (string) in formato (const char *) */
|
||||||
const char* sq_get(string field) { return _rec.get(field.c_str()); }
|
TString sq_get(string field, bool rtrim = true);
|
||||||
/**< Ritorna il valore nel campo (field) passato come (TString) in formato (const char *) */
|
/**< Ritorna il valore nel campo (field) passato come (TString) in formato (const char *) */
|
||||||
const char* sq_get(TString& field) { return _rec.get(static_cast<const char*>(field)); }
|
TString sq_get(TString& field, bool rtrim = true);
|
||||||
/**< Ritorna il valore nel campo (field) in formato (char) */
|
/**< Ritorna il valore nel campo (field) in formato (char) */
|
||||||
const char sq_get_char(const char* field) { return _rec.get_char(field); }
|
const char sq_get_char(const char* field) { return _rec.get_char(field); }
|
||||||
/**< Ritorna la posizione attuale */
|
/**< Ritorna la posizione attuale */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user