Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
jarito
Aug 26, 2003

Biscuit Hider

rotor posted:

jesus christ what the hell

Probably some kind of automated obfuscation app? That's loving horrible. Who would write software to DONATE that was entirely unmaintainable? What a douche.

Adbot
ADBOT LOVES YOU

jarito
Aug 26, 2003

Biscuit Hider

ymgve posted:

It was un-elegant, but I actually had a DB with about 200 columns. Though that was for the result of lab tests, where each test gave 200 distinct values.

I'm not proud of it, though.

My current project has a 180+ column table for medical records since each claim is 180 fields. I argued that we could normalize it further (i.e. don't store duplicate drug descriptions and the like) but I was shot down :(.

jarito
Aug 26, 2003

Biscuit Hider
Here is one from my work:

code:
int transactionSetControl = int.Parse(SystemSettingService.SystemTransactionSetControlNumber);
transactionSetControl++;
string transactionSetControlString = transactionSetControl.ToString();

while (transactionSetControlString.Length < 4)
    transactionSetControlString = "0" + transactionSetControlString;
Issues:
1. TransactionControlNumber stored as a string.
2. Uses a while loop to pad the number.

:sigh:

jarito
Aug 26, 2003

Biscuit Hider

Kharya posted:

Also, gently caress prepared statements.
They're slower when you just want to call it once in a request.
Security worries are moot if the input is sanitized properly.

This is the real horror right here. As someone who does security scanning and training for developers as a living, this never, ever works. Use prepared statements for god's sake.

jarito
Aug 26, 2003

Biscuit Hider

FeloniousDrunk posted:

code:
function bellair(){

...

function bellair2(theForm){

jarito
Aug 26, 2003

Biscuit Hider

Lexical Unit posted:

Please tell me you are a teacher who is grading a high school student's homework.

I've seen MUCH worse on our exam we give to people applying for jobs.

jarito
Aug 26, 2003

Biscuit Hider

Wheany posted:

I read somewhere that often those coding tests aren't really meant to show how clever you are, just to prove that you can program at all.

This is it. We use the test to weed out those that have no chance, then do the actual technical and cultural evaluation of the people that pass.

You'd be surprised how many people will list 3-5 years of web application development on their resume and really have just played with Access and FrontPage.

jarito
Aug 26, 2003

Biscuit Hider

Avenging Dentist posted:

Yes, I too hate things that make generic programming easier and less verbose.

Right, but that's not what we are complaining about. This is:

code:
void someFunc(var a, var b, var c) 
{
    var d = a.Object.DoSomething();
    d.execute();
}
Using var where the typing information is unneeded is fine, but it gives idiots a crutch to turn C# into a weakly typed language, which it is not.

jarito
Aug 26, 2003

Biscuit Hider

Wheany posted:

Maybe they didn't know that in Java you can do a Course [] returnCourses = new Course [numberOfCourses];

Or just use a higher level construct like a List, Hash or Set.

jarito
Aug 26, 2003

Biscuit Hider

MrMoo posted:

I would hedge that Chrome's PDF viewer has more eyes on the security front.

It's also sandboxed away from anything which provides some benefits, although I think the sandbox was breached recently in Pwn2Own or some other contest.

jarito
Aug 26, 2003

Biscuit Hider

BP posted:

The right thing to do (IMO) would be for the validation code to be smart enough that when a record ID is checked that is inside of a range of unusable records, increment to the next ID outside the range instead of incrementing by 1. Instead we only increment by 1, and devs get caught off-guard as this fact about ID generation is not very well known.

Not sure about your use case, but I don't think so. Don't base business logic decisions from auto-incrementing primary keys. Use a separate field or data-type to indicate whatever business case you have.

jarito
Aug 26, 2003

Biscuit Hider

trex eaterofcadrs posted:

Am I the only one who thinks things like Order ID's should just be generated with a UUID? It would solve SO many problems.

IIRC there are some issues in using UUIDs for auto-generating keys in some databases. It's been a while since I looked into it so that might not be an issue anymore.

Even so, using UUIDs doesn't seem to solve his problem since what they need is a way to differentiate two of the same record types. They are using a 'reserved' part of the PK key space which, with UUIDs, would be about a bajillion times worse. It sounds like they just need a separate field.

Adbot
ADBOT LOVES YOU

jarito
Aug 26, 2003

Biscuit Hider

shrughes posted:

They're not abusing a position of power. They aren't in a position of power.

This is correct. The market for developers now is crazy. I read recently that the unemployment rate for devs in Austin is -2%. Negative 2. No one is forcing people to take the job. The only people interested are those that value working for PA highly, which the business is using as part of their compensation package.

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply