New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide ability to autoincrement ID for real-time indexes similar to Oracle Sequence or MS-SQL Identity #92

Open
twelveeighty opened this Issue Jul 12, 2018 · 1 comment

Comments

Projects
None yet
3 participants
@twelveeighty

twelveeighty commented Jul 12, 2018

Provide a way to autoincrement or auto-sequence the ID column for real-time indexes similar to Oracle Sequence or MS-SQL Identity. When inserting records into a real-time index from multiple sources, the caller has to synchronize these sources outside of Manticoresearch in order to prevent collisions on ID values. Perhaps by introducing a new configuration option called "rt_auto_id":

index mxrt
{
	type			= rt
	rt_auto_id = 1

	rt_field		= content
	rt_attr_string		= object
	rt_attr_bigint		= gid
}

INSERT INTO mxrt (content, object, gid) VALUES ('Some content', 'SOME_OBJECT', 1);

And manticore would then automatically assign a valid ID.

Ideally, users would still be able to specify the id when they choose to, but if left out, a safe(guaranteed new) id is automatically assigned.

@airolg

This comment has been minimized.

airolg commented Jul 12, 2018

Added to backlog, thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment