Redshift not loading sorted data as sorted

0

Following this doc: https://docs.aws.amazon.com/redshift/latest/dg/vacuum-load-in-sort-key-order.html

It seems that we're loading things according to these guidelines but our data is still defaulting to loading as unsorted. If we're using a time based sort key and there is overlap in this way:

Existing sort keys in table:

1 2 3

New sort keys in COPY:

3 4 5

Would the overlap on the 3 value explain the behavior we're seeing, even if the data could technically be considered sorted?

preguntada hace 2 años486 visualizaciones
1 Respuesta
0

Yes, I think that is the issue ; the documentation explicitly mentions that new rows are higher:

All the new rows are higher in sort order than the existing rows , including rows marked for deletion. In this instance, Amazon Redshift uses the first eight bytes of the sort key to determine sort order.

hope this helps

AWS
EXPERTO
respondido hace 2 años

No has iniciado sesión. Iniciar sesión para publicar una respuesta.

Una buena respuesta responde claramente a la pregunta, proporciona comentarios constructivos y fomenta el crecimiento profesional en la persona que hace la pregunta.

Pautas para responder preguntas