Segfault-Inc / Multicorn

Data Access Library
https://multicorn.org/
PostgreSQL License
700 stars 145 forks source link

Search by MONEY type causes Segmentation fault? #50

Closed johnmudd closed 10 years ago

johnmudd commented 10 years ago

I tried using a MONEY type field in the WHERE clause but got this in the postgres log.

LOG:  server process (PID 9505) was terminated by signal 11: Segmentation fault
DETAIL:  Failed process was running: SELECT * from reclaim where potential = '12.34'::money;
LOG:  terminating any other active server processes

I verified that my FDW init() method was called and executed normally but there was no call to get_rel_size(), get_path_keys() or execute().

Can anyone test if this is a general problem?

John

rdunklau commented 10 years ago

Thank you for reporting this bug.

I just pushed a change which will allow you to use unsupported types. It does so by converting them to their output representation. So, for money, this would be the locale-formatted value of the amount (ex: 12 €).

There is still another issue wrt encodings I have to fix before closing this issue.

johnmudd commented 10 years ago

Thanks! It's working now.