Tomasz Sowa
958e89fb02
some work in branches/join_models
...
- added FinderHelper class - used as a global object for the whole model tree in Finder
(some fields moved from ModelData)
- added CursorHelper class - used as a global object for the whole model tree in Cursor
(some fields moved from ModelData)
git-svn-id: svn://ttmath.org/publicrep/morm/branches/join_models@1192 e52654a7-88a9-db11-a3e9-0013d4bc506e
2019-05-21 15:51:13 +00:00
Tomasz Sowa
b37a577713
some work in branches/join_models
...
added: ModelEnv class - now Model has a pointer to ModelEnv
and ModelEnv has a pointer to ModelData, model_connector_mode, table_index and doc_field_pointer
git-svn-id: svn://ttmath.org/publicrep/morm/branches/join_models@1191 e52654a7-88a9-db11-a3e9-0013d4bc506e
2019-05-13 17:59:28 +00:00
Tomasz Sowa
34ddf11351
some work in branches/join_models
...
git-svn-id: svn://ttmath.org/publicrep/morm/branches/join_models@1190 e52654a7-88a9-db11-a3e9-0013d4bc506e
2019-05-13 03:12:31 +00:00
Tomasz Sowa
6d9b9045fe
fixed: generating a correct table names with indices for JOIN statements and column prefixes
...
git-svn-id: svn://ttmath.org/publicrep/morm/branches/join_models@1188 e52654a7-88a9-db11-a3e9-0013d4bc506e
2019-03-31 20:21:12 +00:00
Tomasz Sowa
ab54a3fc3e
some work: we need a different way of naming tables for joins
...
git-svn-id: svn://ttmath.org/publicrep/morm/branches/join_models@1187 e52654a7-88a9-db11-a3e9-0013d4bc506e
2019-03-26 20:35:05 +00:00
Tomasz Sowa
9c7a0f3d7e
added: support for generating LEFT JOIN statement in Finder
...
(the primary key should consist of only one column at the moment)
git-svn-id: svn://ttmath.org/publicrep/morm/branches/join_models@1186 e52654a7-88a9-db11-a3e9-0013d4bc506e
2019-03-26 18:34:07 +00:00
Tomasz Sowa
440f56e376
creating branch branches/join_models
...
git-svn-id: svn://ttmath.org/publicrep/morm/branches/join_models@1185 e52654a7-88a9-db11-a3e9-0013d4bc506e
2019-03-26 18:22:21 +00:00
Tomasz Sowa
79f9522708
used PT::Log::logsave in postgresqlconnector in some places
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1181 e52654a7-88a9-db11-a3e9-0013d4bc506e
2019-03-19 17:54:33 +00:00
Tomasz Sowa
48b04fb5de
fixed in Finder: in select(ModelConnector & model_connector) there was not an out_stream set
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1177 e52654a7-88a9-db11-a3e9-0013d4bc506e
2019-03-08 18:32:58 +00:00
Tomasz Sowa
cf0a0c96fe
changed: ModelData moved outside Model
...
added: using ModelData in BaseExpression so Model::to_text() functions can use a ModelData object now
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1175 e52654a7-88a9-db11-a3e9-0013d4bc506e
2019-03-07 18:02:29 +00:00
Tomasz Sowa
41684eb969
Makefile.dep
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1165 e52654a7-88a9-db11-a3e9-0013d4bc506e
2019-01-07 04:33:31 +00:00
Tomasz Sowa
eb3703c323
updated to the new pikotools api
...
(Logger -> Log)
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1150 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-11-23 17:13:50 +00:00
Tomasz Sowa
8c5eaacadb
changed: testing result status in do_query() in PostgreSQLConnector
...
renamed: some fields in QueryResult and PostgreSQLQueryResult
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1142 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-11-15 08:50:10 +00:00
Tomasz Sowa
1f9e4ee70a
added Cursor class
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1140 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-11-14 17:14:26 +00:00
Tomasz Sowa
011d8f96e8
fixed: in Finder: we should set model_data to nullptr after fetching an object
...
model_data points often to a local object (on the stack) so it would be incorrect
to use it in the future
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1131 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-10-24 16:28:19 +00:00
Tomasz Sowa
346fe193f3
start working on generating documentation from a model
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1124 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-07-15 22:36:04 +00:00
Tomasz Sowa
fdc44c56eb
added: a new class Clearer with clear_value() methods moved from DbConnector
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1122 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-07-05 11:15:16 +00:00
Tomasz Sowa
38b85722b8
Model and BaseExpression: changed the template taking a container to std::list
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1121 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-07-05 09:51:26 +00:00
Tomasz Sowa
d6e428d929
removed: set_connector_for_childs from ModelConnector
...
changed: model connector is propagated to childs when needed
(when update, insert, save, to_text is called or in finder)
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1120 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-07-04 13:52:40 +00:00
Tomasz Sowa
08cd621d41
changed: some methods from ModelConnector moved to Model
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1119 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-07-04 11:34:49 +00:00
Tomasz Sowa
f85f03a889
some work in morm
...
now in Model we have field() methods for other Model or std::list<Model>
(code not tested)
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1118 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-07-03 16:55:06 +00:00
Tomasz Sowa
6fc4e23e44
changed: don't use column prefix in add_field_for_select()
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1107 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-05-02 12:55:00 +00:00
Tomasz Sowa
e25b6d9a29
added: Finder::prefix() method
...
code not thoroughly tested
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1106 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-05-01 23:22:32 +00:00
Tomasz Sowa
98206fdb7a
added: field_model() method to Model
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1103 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-04-26 18:58:31 +00:00
Tomasz Sowa
3da8d1f411
fixed: finder.get() didn't check whether the resultset had exactly one item
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1098 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-04-23 19:02:38 +00:00
Tomasz Sowa
cc2230001c
added support for PT::Logger to DbConnector and PostgreSQLConnector
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1097 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-04-23 15:46:21 +00:00
Tomasz Sowa
fd1cc7debe
added: Model::ModelData base class to use with Finder, Model.update(), Model.insert() and Model.remove()
...
added: Model.add_field_for_select() method
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1092 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-04-22 21:04:50 +00:00
Tomasz Sowa
4c0d203fc8
added:
...
removing objects
saving objects (either insert or update or remove)
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1091 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-04-22 01:26:46 +00:00
Tomasz Sowa
925017300b
PT::Date is serializing in the form YYYY-MM-DDTHH:MM:SSZ (eg: 1990-02-12T13:05:39Z) to JSON
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1090 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-04-20 09:41:41 +00:00
Tomasz Sowa
c7bd935a80
added: Model::get_connector_mode() method
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1088 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-04-19 15:21:51 +00:00
Tomasz Sowa
5bccb056d7
poprawka: get_value() z postgresqlconnector zamienione na get_value_from_result()
...
w klasie bazowej mamy virtualne get_value() z innymi parametrami
(ostrzeżenie kompilatora)
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1087 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-04-19 11:37:10 +00:00
Tomasz Sowa
476e5de292
added support for 'in()' statement in 'select'
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1086 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-04-18 17:52:09 +00:00
Tomasz Sowa
ffb7ac85a6
added: QueryResult stack to PostgreSQLConnector
...
this allowes us to call query() recursively (from after_select() callback)
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1085 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-04-18 10:22:01 +00:00
Tomasz Sowa
7bae5224e5
temporarily changed the way how PT::Date is escaped
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1084 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-04-17 16:01:14 +00:00
Tomasz Sowa
72b2622d08
some work in morm
...
- support for fetching rows from db
- support for inserting/updating rows
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1081 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-04-16 22:46:25 +00:00
Tomasz Sowa
09f31b2803
some work in morm (select statement)
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1079 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-04-15 23:00:17 +00:00
Tomasz Sowa
b1af7b8d25
changed: esc() function for bool uses now 'true' and 'false' strings
...
added: esc() for PT::Date
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1078 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-04-12 16:05:14 +00:00
Tomasz Sowa
fceec43d07
some work for SELECT statement
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1077 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-03-30 19:34:45 +00:00
Tomasz Sowa
d84ca900c3
reorganizing class hierarchy
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1075 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-03-23 19:26:57 +00:00
Tomasz Sowa
de7fc912bb
set svn:ignore to eclipse files
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1073 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-03-13 22:24:06 +00:00
Tomasz Sowa
c7327750bd
start creating a new project: Micro ORM
...
git-svn-id: svn://ttmath.org/publicrep/morm/trunk@1072 e52654a7-88a9-db11-a3e9-0013d4bc506e
2018-03-13 22:22:17 +00:00