I'm trying this : articles/sql-database/sql-database-elastic-scale-configure-deploy-split-and-merge.md
Experiment with other data types!
All of these scripts take an optional -ShardKeyType parameter that allows you to specify the key type.
The default is Int32, but you can also specify Int64, Guid, or Binary.
Can I use also DateTime ?
What should I enter to the [Split at Key] form ?
Trying "2010-07-01", then an ArgumentException is shown.
"40358" is same result.
(40358 is calculated by SELECT Convert(float, CONVERT(datetime, '2010/07/01')))


"0x88CCE6C77BA9C000" resulted in the other exception.
(configured in [__ShardManagement].[ShardMappingsGlobal].[MaxValue])
Status: Failed
Details: [Error] Failed to process request.
Microsoft.Azure.SqlDatabase.ElasticScale.SplitMerge.Worker.InvalidSplitMergeOperationException:
The specified shard map 'xxxxx' with key type Binary could not be found.
---> Microsoft.Azure.SqlDatabase.ElasticScale.ShardManagement.ShardManagementException:
Shard map 'xxxxx' can not be converted to the target type RangeShardMapIts actual type is RangeShardMap<DateTime>.
Finally I left it blank.
but the exception sais "The field 'Split Key' is mandatory and cannot be left blank".
What should I do?
Regards, thank you.
⚠Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.
Thank you for reaching out.
We are actively investigating and will get back to you soon.
@mijp The ShardKey expects a datetime as documented here
Could you please try providing the value in this format
2019-12-01 22:17:28.920
@stevestein Could you please evaluate if the shardkey format needs to be documented with examples?
@KalyanChanumolu-MSFT
Thank you for your reply.
It does n’t work.
Are there other problems?


@mijp - thanks for the feedback!
I haven't tested this, and I'd need to find someone with knowledge of the split-merge tool, but based on the error message I'd probably experiment with trying to pass the date as a binary key that the exception info is indicating. I'm not sure about converting dates to binary values, but maybe something like this will help get past the exception:
DECLARE @dt DateTime
SET @dt = '12/31/2019'
SELECT CONVERT(binary, @dt,1)
@stevestein
Thank you for your reply.
I thought there was no information, so deleted the app-service and databases. (because not free..)
I will try again later.
Thanks