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.
 
  • Locked thread
HappyHippo
Nov 19, 2003
Do you have an Air Miles Card?

why isn't c and c++ there?

Adbot
ADBOT LOVES YOU

30 TO 50 FERAL HOG
Mar 2, 2005



doin something random at work today in c# and had a file path too long exception

https://blogs.msdn.microsoft.com/bclteam/2007/02/13/long-paths-in-net-part-1-of-3-kim-hamilton/

heres a 9 year old article on msdn about file paths and how they are thinking about maybe doing something about it (they didnt)

HoboMan
Nov 4, 2010

i just got hired as a C# dev with zero experience, i have found my new home in this thread

Bloody
Mar 3, 2013

how many figgies

Jerry Bindle
May 16, 2003
i got hired as a java dev with 0 experience a while back and my body and mind are being being destroyed by stress. the figgies and the hours are good, but the minutes are terrible.

HoboMan
Nov 4, 2010

im only getting paid slightly above the bottom of the typical range given for my area and title from salary sites

still more money than i know wat to do with

HoboMan
Nov 4, 2010

right now i'm posting instead of working because they said this thing i got assigned should take me a couple days, but i'm almost done copy-pasting all the code :shrug:

Hunter2 Thompson
Feb 3, 2005

Ramrod XTreme

HoboMan posted:

im only getting paid slightly above the bottom of the typical range given for my area and title from salary sites

still more money than i know wat to do with

make a fort out of the money, live in it

CPColin
Sep 9, 2003

Big ol' smile.

Barnyard Protein posted:

i got hired as a java dev with 0 experience a while back and my body and mind are being being destroyed by stress. the figgies and the hours are good, but the minutes are terrible.

I like that. "The hours are good, but the minutes are terrible."

Edit: Oh it's just a Hitchhikers Guide line.

KidDynamite
Feb 11, 2005

I've only done iOS and xamarin work and somehow I got stuck designing the DB and APIs for a new app at work. How to learn DB and API design? Also I'm picking SQL for the DB because I've read this thread enough

HoboMan
Nov 4, 2010

no, use mongodb it's infintetly customizeable!

HoboMan
Nov 4, 2010

just to be clear, don't use mongodb i was making a joke. i don't want my jokes to lead to someone actually using mongodb i would have trouble sleeping at night at the thought

Shaggar
Apr 26, 2006

java doesn't, but javascript and ruby sure do

Shaggar
Apr 26, 2006

KidDynamite posted:

I've only done iOS and xamarin work and somehow I got stuck designing the DB and APIs for a new app at work. How to learn DB and API design? Also I'm picking SQL for the DB because I've read this thread enough

use MSSQL server and ASP.net 5 WebAPI

HoboMan
Nov 4, 2010

poo poo, I am faced with a situation where there is no code I can just copy-paste to do the thing. i guess this gravy train was fun while it lasted

Soricidus
Oct 21, 2010
freedom-hating statist shill

HoboMan posted:

i just got hired as a C# dev with zero experience, i have found my new home in this thread

HoboMan posted:

right now i'm posting instead of working because they said this thing i got assigned should take me a couple days, but i'm almost done copy-pasting all the code :shrug:

congratulations and welcome!

HoboMan posted:

poo poo, I am faced with a situation where there is no code I can just copy-paste to do the thing. i guess this gravy train was fun while it lasted

welp, :rip: then

Valeyard
Mar 30, 2012


Grimey Drawer
the last dev on project python last day was today, so I am now the sole dev on it

The MUMPSorceress
Jan 6, 2012


^SHTPSTS

Gary’s Answer

HoboMan posted:

poo poo, I am faced with a situation where there is no code I can just copy-paste to do the thing. i guess this gravy train was fun while it lasted

did you used to live in my upstairs? you sound like someone i used to know :D

AWWNAW
Dec 30, 2008

HoboMan posted:

poo poo, I am faced with a situation where there is no code I can just copy-paste to do the thing. i guess this gravy train was fun while it lasted

post problem here and copy paste code from replies

Soricidus
Oct 21, 2010
freedom-hating statist shill

AWWNAW posted:

post problem here and copy paste code from replies

what could possibly go wrong

Deep Dish Fuckfest
Sep 6, 2006

Advanced
Computer Touching


Toilet Rascal

HoboMan posted:

just to be clear, don't use mongodb i was making a joke. i don't want my jokes to lead to someone actually using mongodb i would have trouble sleeping at night at the thought

besides, mongo is just too mainstream these days. you need to go for something even less widely known, preferably with the most hosed up data and consistency model you can find

Finster Dexter
Oct 20, 2014

Beyond is Finster's mad vision of Earth transformed.
gently caress MySqlDataReader right now. Why won't it just work like SqlDataReader? I keep doing reader.read() but it gives me the same values every Read() call. I have a 3 row result set. I can execute and see the results in mysql but when the MySqlDataReader does it, it gives me three rows, but they are all the same row.

I'm going to chalk this up to MySql because I'm not very good at programming, apparently

Finster Dexter
Oct 20, 2014

Beyond is Finster's mad vision of Earth transformed.

YeOldeButchere posted:

besides, mongo is just too mainstream these days. you need to go for something even less widely known, preferably with the most hosed up data and consistency model you can find

CouchDB, I choose you!

HoboMan
Nov 4, 2010

YeOldeButchere posted:

besides, mongo is just too mainstream these days. you need to go for something even less widely known, preferably with the most hosed up data and consistency model you can find
but you see the beauty of mongo is it lets you gently caress that all up yourself

Zaxxon
Feb 14, 2004

Wir Tanzen Mekanik

Finster Dexter posted:

CouchDB, I choose you!

I'd take couch over mongo any time. I mean postgres JSON makes them both pointless but at least couch actually wrote stuff to disk.

Finster Dexter
Oct 20, 2014

Beyond is Finster's mad vision of Earth transformed.

Zaxxon posted:

I'd take couch over mongo any time. I mean postgres JSON makes them both pointless but at least couch actually wrote stuff to disk.

100% agree, but conflict resolution in Couch is... interesting. The best part was that if a document got several conflicts, a DELETE request would get rid of the default document, and one of the other conflicted versions would happily take its place, leaving you to wonder why this document is still here that I just deleted.

But yeah, count me as a fan of postgres JSON. I loved how Mongo's BI suite ended up just being a layer on top of postgres.

AWWNAW
Dec 30, 2008

lol if your not using potatobase in 2016

Finster Dexter
Oct 20, 2014

Beyond is Finster's mad vision of Earth transformed.

Finster Dexter posted:

gently caress MySqlDataReader right now. Why won't it just work like SqlDataReader? I keep doing reader.read() but it gives me the same values every Read() call. I have a 3 row result set. I can execute and see the results in mysql but when the MySqlDataReader does it, it gives me three rows, but they are all the same row.

I'm going to chalk this up to MySql because I'm not very good at programming, apparently

Oh dear god.



It was my lovely SQL statement that was causing it. dammit I loving suck

Spent all day trying to figure this out. holy loving poo poo :negative:


e: I love that feeling though, of closing down like 20 browser tabs of google searches and stackoverflow questions. Feel like my day can finally begin :wtc:

Finster Dexter fucked around with this message at 21:59 on Mar 22, 2016

Bloody
Mar 3, 2013

you are in the right place :)

HoboMan
Nov 4, 2010

can someone unpack this for me? i know what it returns but gently caress if i know what the hell 'p => p.Value' is or does or whatever (also p is no where else in this function)
this is from a lovely c#/ASP.NET webapp by the way
code:
fConfirmed.CheckedItems.ToList().Select(p => p.Value).ToArray();

HoboMan fucked around with this message at 22:01 on Mar 22, 2016

Finster Dexter
Oct 20, 2014

Beyond is Finster's mad vision of Earth transformed.

Bloody posted:

you are in the right place :)

:v:

piratepilates
Mar 28, 2004

So I will learn to live with it. Because I can live with it. I can live with it.



HoboMan posted:

can someone unpack this for me? i know what it returns but gently caress if i know what the hell 'p => p.Value' is or does or whatever (also p is no where else in this function)
code:
fConfirmed.CheckedItems.ToList().Select(p => p.Value).ToArray();

=> is a lambda function. It means Select(...) is passed a function that takes a parameter called 'p' and returns the result of 'p.Value'

Edit: it looks like Select is what is called in every other function a map function on a list.

It takes the CheckedItems property, calls ToList to turn it in to a list, calls Select/map to make a new list where every element gets an element in the new list from the result of the lambda function in Select, then ToArray turns it in to an array.

Basically it just gives an array of the Value properties for whatever is in CheckedItems.

piratepilates fucked around with this message at 22:05 on Mar 22, 2016

Bloody
Mar 3, 2013

HoboMan posted:

can someone unpack this for me? i know what it returns but gently caress if i know what the hell 'p => p.Value' is or does or whatever (also p is no where else in this function)
code:
fConfirmed.CheckedItems.ToList().Select(p => p.Value).ToArray();

"p => p.Value" is a lambda expression - what this is doing is taking the collection fConfirmed.CheckedItems.ToList() and applying Select to that collection with that lambda. Select takes a lambda that takes a single parameter and returns a single value, and runs that function along each item in the collection; the return value of the lambda applied to each element is used to build a new collection. calling ToArray() on that enumerable forces evaluation (because Select is lazy) and creates the collection. it's a bit like this, but more concise:

var newCollection = new List();
foreach(var x in collection)
newCollection.Add(x.Value)

Finster Dexter
Oct 20, 2014

Beyond is Finster's mad vision of Earth transformed.

piratepilates posted:

=> is a lambda function. It means Select(...) is passed a function that takes a parameter called 'p' and returns the result of 'p.Value'

Oh man, you're on the brink of understanding exactly how LINQ works. Very exciting time, tbh. Once I learned all about lambdas I became a LINQ master.

Bloody
Mar 3, 2013

linq is awesome & really good and functional programming is awesome & really good

jesus WEP
Oct 17, 2004


linq is so good that i get legit annoyed when i have to go back to java and write foreach loops like a caveman

piratepilates
Mar 28, 2004

So I will learn to live with it. Because I can live with it. I can live with it.



St Evan Echoes posted:

linq is so good that i get legit annoyed when i have to go back to java and write foreach loops like a caveman

Get out of the past man, Java got weirdo linq with the Java 8 streams. Some of linq while still having the weirdness of java

Finster Dexter
Oct 20, 2014

Beyond is Finster's mad vision of Earth transformed.
Yeah, I want to get into more functional programming. I keep trying to convince my co-workers that we should write our services in F# but they just look at me weird. I had one other guy on my side, but then I left that job.

jesus WEP
Oct 17, 2004


i still have to target java 1.5 because reasons :smith:

Adbot
ADBOT LOVES YOU

piratepilates
Mar 28, 2004

So I will learn to live with it. Because I can live with it. I can live with it.



St Evan Echoes posted:

i still have to target java 1.5 because reasons :smith:

I am sorry for your loss

  • Locked thread