Re: int8 sequences --- small implementation problem
| От | Neil Padgett |
|---|---|
| Тема | Re: int8 sequences --- small implementation problem |
| Дата | |
| Msg-id | 3B795BFA.37EC642@redhat.com обсуждение исходный текст |
| Ответ на | Re: Surviving transaction-ID wraparound, take 2 (Jan Wieck <JanWieck@Yahoo.com>) |
| Список | pgsql-hackers |
Tom Lane wrote:
[clip]
>
> This would work, I think, but my goodness it's an ugly solution.
> Has any hacker got a better one?
>
> regards, tom lane
How about:
#ifdef INT64_IS_BUSTED
#define int64aligned(name) int32 name##_; int64 name
#else
#define int64aligned(name) int64 name
#endif
typedef struct FormData_pg_sequence
{ NameData sequence_name; int64aligned(last_value); int64aligned(increment_by);
int64aligned(max_value); int64aligned(min_value); int64aligned(cache_value); int64aligned(log_cnt);
char is_cycled; char is_called;
} FormData_pg_sequence;
Neil
--
Neil Padgett
Red Hat Canada Ltd. E-Mail: npadgett@redhat.com
2323 Yonge Street, Suite #300,
Toronto, ON M4P 2C9
В списке pgsql-hackers по дате отправления: