Are you going to lookup a price and enter it manually for every task? How about a table with base-tasks and pricing to choose from? Perhaps with an additional column for discounts or extra?
Also, you use autonumbers for your keys; That means you can enter a customer twice, without problems. I'd prefer a unique constraint on the autonumber, and a PK on the customers name. It's a nice way to ensure that there's a single unique identifyable customer for each project. It'd also mean that a project would require a unique constraint on its autonumber for quick reference, but also a decent PK; the combination of the username and the projectname.
Free tip; if you're unsure about a structure, populate your example with mock-data and try some queries
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
"If you just follow the bacon Eddy, wherever it leads you, then you won't have to think about politics." -- Some Bell.
This site has no support for sending attachments, so I use mediafire to send attachments, if your computer is blocked you can bypass the firewall using psiphon3.exe software, you can download this software at address Download Psiphon 3 for PC Windows 7/8/8.1/10 or XP Laptops
Soon receive your feedback
My data SQL Server is reported this error, How does this error fix you ?
SQL Server detected a logical consistency-based I/O error: torn page (expected signature: 0xaaaaaaaa; actual signature: 0x5555aaaa). It occurred during a read of page (1:210768) in database ID 7 at offset 0x00000066ea0000 in file 'G:\Database\MyData.mdf'. Additional messages in the SQL Server error log or system event log may provide more detail. This is a severe error condition that threatens database integrity and must be corrected immediately. Complete a full database consistency check (DBCC CHECKDB). This error can be caused by many factors; for more information, see SQL Server Books Online.
During redoing of a logged operation in database 'MyData', an error occurred at log record ID (30182:834:13). Typically, the specific failure is previously logged as an error in the Windows Event Log service. Restore the database from a full backup, or repair the database.
Could not open new database 'MyData'. CREATE DATABASE is aborted. (Microsoft SQL Server, Error: 824)
SQL server database 824 error means that the page has been read successfully from the disk but there is some issue with the page. Other types of messages that might be shown are “fatal error 824 occurred” , “SQL server detected logical consistency based i/o error”. The exact display message can be more helpful in understanding this problem.
As far as multiple adds, that's a modelling issue. If it's allowable, use PUT. If it's not, use POST and make sure your model checks against field combinations that should be unique. Worst case scenario, use a wrapper with a unique identifier (such as a transaction ID) to avoid multiple inserts.
All that said: when working with REST you should not think of efficiencies in terms of round trips. REST apps are chatty. Instead, efficiencies lie in conformance to standard providing a consistent interface, and providing ways to query and slice up collections effectively.
"Never attribute to malice that which can be explained by stupidity."
- Hanlon's Razor
As far as multiple adds, that's a modelling issue.
What I meant was there could be any number of clients adding records at the same time. If you had to requery after YOUR instance did an add, you could get back any number of records added by ANY client instance since you did the add. You would have no way of kowing what record YOUR client added versus other clients.
Not sure what Modeling has to do with this
If it's not broken, fix it until it is.
Everything makes sense in someone's mind.
Ya can't fix stupid.