I am an IT manager for a smallish company (<50 employees)
What that means in practical terms is that I do a very broad range of different things, from support to programming, software, hardware, configuration etc - the lot, at every level. I work more or less alone, sometimes contracting people in for larger hardware jobs (I like it this way, as it is very varied)
I used to work as development manager for a smaller company, which was taken over by the company I now work for and I was promoted to the more responsible and general role I now have; I report to the company chairman, who also happens to be the guy who wrote all the (larger)company’s software before I came along.
He is an interesting man of very strong ideas, but the trouble is that he is just wrong about a lot of stuff - he is very focused on (programming)‘style’, which of itself is not a bad thing, but being largely beyond criticism, he is often under the impression that whatever ‘style’ his fancy happens to run to is objectively the best and only way to do things.
Last couple of days, he has been ‘advising’ me on correct style; a few examples of this:
1 - I’m developing an application that needs to store documentary data in a goods inward department - the data describes deliveries, each of which contains one or more products (usually many).
My plan was to implement a relational database with two main tables - one of them containing single records for each delivery received (with data pertaining to the carrier, vendor and consignment attributes) and a second table containing the details of the delivered lines, quantities, condition etc.
My boss is not in favour of this model, because apparently ‘people are moving away from the flaky relational database model now’ and I am to store all the data in a single table - every delivered product detail line will carry fields populated with the details of carrier, vendor and consignment.
2 - The program structure itself is under question; one of my favourite techniques is to write a library of custom functions, then use them extensively and in various combinations, so I’d write a function called, say, ‘CarriageCost’ that calculates the carriage value based on weight and another generic function called ‘AddVAT’ that adds VAT(tax) onto any number you pass it, then to calculate the total cost of a delivery, including carriage, I’ll use a nested expression like:
totalvalue := AddVAT(InvoiceValue+CarriageCost(Weight))
This isn’t correct, apparently; what I’m supposed to do is use Procedures rather than functions, and pass values to and from them by setting and reading public variables. I’m also not supposed to nest expressions - I have to do everything in steps, even if this means defining extra variables to store intermediate results.
3- ‘It isn’t good practice’ to use nested loops or conditions; instead of:
(pseudocode)
If [condition A] then
do process X
do process Y
If [condition B] then
do process Z
end if
end if
(where X and Y are done on A OR, but Z is only done on A AND B, I have to do:
If [condition A] then
do process X
do process Y
Set flag Q
end if
If [condition B] AND flag Q then
do process Z
end if
(except that even this is frowned upon because boolean operators in IF statements are ‘too complex for someone else to debug’
4- There are to be no subprocedures - if processing control is currently in a called procedure, I can’t call another procedure, no matter how simple or necessary it is - this makes for a lot of duplicated code or unnecessary status flags; for example, if I have a procedure that updates some values in a table, I can’t call the generic screen-refresh procedure from the end of the update procedure, I have to either:
-Paste the entire screen-refresh code into the end of the update procedure, or
-Set a control flag (another public variable) that will tell the main program that the screen needs refreshing, so that the screen refresh will be called after control has passed back to the main program.
I’m not the best programmer in the world, I’ll admit and I’m sure I don’t always do things in the most efficient manner, but assertions about programming standards that are just contrary to fact, convenience and common sense are driving me crazy; I sometimes argue at great length in favour of (my particular idea of) good program and data structure, but he just isn’t hearing me (in fact I can sometimes see him mentally composing his rebuttal before he’s even heard me out).
So why don’t I change jobs?
I’m a generalist - I get involved in everything - jobs like mine where breadth is more important than any specific depth(as long as I can quickly attain resonable depth on a pertinent subject) aren’t all that common and I probably don’t have enough concentrated strength in any one area to get a job doing just that function.
The pay and conditions are actually quite good.
ANY sound advice (or just sympathy) on this would be appreciated.