# Reporting documentation

## Issue: Unreadable name and description of the voucher

### Tables: [rentals_vouchers](../snowflake-tables/rentals_vouchers.md), [vouchers](../snowflake-tables/vouchers.md), [voucherables](../snowflake-tables/voucherables.md), [message_resources](../snowflake-tables/message_resources.md)

Solution: The name, descriptions for the listed tables are localised and are translated in the backend based on language/region the user selected. Name and description are foreign keys for the table message_resources, where the actual name of the voucher is stored in a column ‘value’. Use columns name and description in order to get the respective value of a voucher. 

Here is an example sql to do that: 

```sql
select
	v.id,
	v.name,
	mr1.value as name_translated,
	v.description,
	mr2.value as description_translated
from
	vouchers v
left outer join message_resources mr1 on
	v.name = mr1.code
	and mr1.language = ''
	and mr1.country = ''
left outer join message_resources mr2 on
	v.description = mr2.code
	and mr2.language = ''
	and mr2.country = ''
```

## Issue: ERROR_MESSAGE Column not populated in table PAYMENT_ATTEMPTS

### Table: [payment_attempts](../snowflake-tables/payment_attempts.md)

Solution: Error messages are only given, where different subclasses mean different things. When a few subclasses mean the same thing (for example errors **P103.17** and **P103.7**) then the subclass is omitted. The subclass in that case is only useful for Wunder Engineering cause it allows us to know where it originated from.
