Skip to content

PAGE_SIZE must be higher than max row count in SQL Server #1

@unixmonkey

Description

@unixmonkey

Thanks, this is just what I needed, but one note; on SQL Server as the production DB (at least in version 2005), if there are more records in a single table than the PAGE_SIZE is set to, The next loop will try to start over, and the primary_key constraint will cause it to choke by trying to re-insert the record with an ID of 1. This has to do with the limited support for LIMIT and OFFSET in SQL server. Raising the LIMIT to over the limit of the highest row count works fine. Just thought you should know, maybe put it in the readme, or check if ProductionModelClass.connection.adapter_name == 'SQLServer'.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions