sedos-project / data_adapter_oemof

This respository holds the data adapters to connect oemof with the OEDatamodel-concrete.
GNU Affero General Public License v3.0
0 stars 1 forks source link

Add get foreign keys #36

Closed FelixMau closed 12 months ago

FelixMau commented 1 year ago

Adding Foreign keys iterative

contributing to #31

Adding Foreign keys while iterating for each row in scalar Data and Parametrizing. Moved Mapper creation outside of parametrize_dataclass to avoid recreation of same class and to be able to make use of the class outside of parametrize_dataclass

Foreign keys could also be derived from the datapackage after it is successfully build To do that it might be necessary to make mapper.is_sequence() callable from outside mapper (maybe as "regular function"?) This would also bear the advantage for adding in "default" foreign keys in a more clean way if necessary?

I will be happy to hear your toughts and feedback on this @henhuy @nailend

nailend commented 12 months ago

We can discuss this today - this PR alos needs another PR which saves the timeseries in a correct way, so that foreign keys can find correct files... Maybe this clarifies a bit, what problem get_foreign_keys function has to solve.

@FelixMau Is #37 the 'other PR' @henhuy was talking about?

FelixMau commented 12 months ago

37 does not include changes on foreign keys.