RepoDB: Bug: Insert exception since 1.1.3 with mysql...
hi again
great to see the project moving forward to even better things - thanks for all the work 😃
since the upgrade to 1.1.3 insertall<>() code that used to work (and old builds do still work) fails with the following exception:
Expression of type ‘System.Int32’ cannot be used for parameter of type ‘System.Int64’ of method ‘Void set_id(Int64)’
what info would you need to guess at what might be causing this? the model is as follows:
using RepoDb.Attributes;
namespace dsync.Models
{
[Map("zaudit_response")]
class ZauditResponse
{
[Map("audit_id")]
public long id { get; set; }
public int code { get; set; }
public string guid { get; set; }
public string action { get; set; }
public string table { get; set; }
public string msg { get; set; }
}
}
the table create is:
CREATE TABLE `zaudit_response` (
`id` INT(11) NOT NULL AUTO_INCREMENT,
`audit_id` BIGINT(20) NULL DEFAULT NULL,
`code` INT(11) NULL DEFAULT NULL,
`rtimestamp` TIMESTAMP NULL DEFAULT CURRENT_TIMESTAMP,
`guid` VARCHAR(30) NULL DEFAULT NULL COLLATE 'utf8_general_ci',
`action` VARCHAR(30) NULL DEFAULT NULL COLLATE 'utf8_general_ci',
`table` VARCHAR(30) NULL DEFAULT NULL COLLATE 'utf8_general_ci',
`msg` VARCHAR(2000) NULL DEFAULT NULL COLLATE 'utf8_general_ci',
PRIMARY KEY (`id`) USING BTREE,
INDEX `audit_id` (`audit_id`) USING BTREE,
INDEX `table` (`table`) USING BTREE,
INDEX `zaudit_response_rtimestamp_index` (`rtimestamp`) USING BTREE
)
COLLATE='utf8_general_ci'
ENGINE=InnoDB
as i said, if i run the app built with versions before 1.1.3 everything works as always
any help appreciated
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 15 (15 by maintainers)
Commits related to this issue
- #765 - Fixes for "Bug: Insert exception since 1.1.3 with mysql..." — committed to mikependon/RepoDB by mikependon 3 years ago
- Merge pull request #766 from mikependon/repodb-identity-diverted #765 - Fixes for "Bug: Insert exception since 1.1.3 with mysql..." — committed to mikependon/RepoDB by mikependon 3 years ago
RepoDbInsertDemo.zip
will do - thanks