Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Head-breaking query
Message
From
21/09/2016 08:27:09
 
General information
Forum:
Microsoft SQL Server
Category:
SQL syntax
Miscellaneous
Thread ID:
01641137
Message ID:
01641166
Views:
47
>What is the query you tried? By the way, decimal (1,0) has no sense. You should have used tinyint instead. Also, why all columns are nullable? What is the primary key for the table? Can you have NULL in StoreCode and in DayNumber columns?
>

I understand your point in general, but the "decimal(1,0) has no sense" isn't entirely accurate. Assuming that was being used for the numeric day of week (1-7) , it "will" work, though I admit that's the first time I think I've ever seen that.

Yes, a tinyint (and a constraint of values 1-7) is definitely preferable, but I wouldn't say "decimal (1,0) has no sense".

(Well, to make a bad pun, it's true that decimal(1,) has no "cents" ) :)
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform