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
redleader
Aug 18, 2005

Engage according to operational parameters

abraham linksys posted:

using double-equals is so uncommon in js these days

i can assure you that it is, in fact, not uncommon

Adbot
ADBOT LOVES YOU

Xarn
Jun 26, 2015

LeftistMuslimObama posted:

c++ but do it all with templates and implement a modding script language using boost::spirit

:getin:

Shaggar
Apr 26, 2006

Bloody posted:

webapi projects build into a dll i guess? how do i host this on a local machine outside of launching it from the debugger. do i have to gently caress around a bunch with iis or something? i just wanna hit run

are you using iis express right now? if so just publish it to the destination IIS server. its ez.

Shaggar
Apr 26, 2006

BiohazrD posted:

but i thought microsoft could do no wrong

ORMs are bad and entity framework is a very bad orm.

Shaggar
Apr 26, 2006

kalstrams posted:

thinking about trying to write a simple rpg game to check out a new language. c++, c#, or java - thoughts?

java or c# but probably c#

HoboMan
Nov 4, 2010

Shaggar posted:

ORMs are bad and entity framework is a very bad orm.

orm is good, just make sure you map the database into objects instead of the other way around (which no one does)

Bloody
Mar 3, 2013

Shaggar posted:

are you using iis express right now? if so just publish it to the destination IIS server. its ez.

idk I just press play in visual Studio. there is no destination server yet and I want the least hassle in setting one up

Finster Dexter
Oct 20, 2014

Beyond is Finster's mad vision of Earth transformed.

Shaggar posted:

ORMs are bad and entity framework is a very bad orm.

:agreed:

One of the big problems with ORM, HoboMan, is that they are supposed to be a database abstraction... except they are a very bad abstraction because any scenario outside of the simplest use cases require you to know/understand the implementation details of how the ORM is generating SQL, otherwise you start running into huge performance issues. So, what did it save you?

You're usually better off just building a thin repository layer with hardcoded SQL statements (or use a SQL bulder or whatever idc) that returns your data objects.

Lutha Mahtin
Oct 10, 2010

Your brokebrain sin is absolved...go and shitpost no more!

HoboMan posted:

orm is good, just make sure you map the database into objects instead of the other way around (which no one does)

i do. by hand. uphill. both ways.

Shaggar
Apr 26, 2006
statement mappers and stored procs are the best

Sapozhnik
Jan 2, 2005

Nap Ghost

Shaggar posted:

ORMs are bad

here's what i've learned in the last few years:

orms are bad

the alternatives are worse

Shaggar
Apr 26, 2006
statement mappers are so much better

HoboMan
Nov 4, 2010

Shaggar posted:

statement mappers are so much better

I can agree with this

i think of orm as a thing you do if database load is not a concern. then it's great because you don't have to write any sql. i will admit this is not very common though

e: it's also good if you hate your dba and will never be on the hook for poor database perfomance

HoboMan fucked around with this message at 15:10 on Jul 28, 2016

Notorious b.s.d.
Jan 25, 2003

by Reene

HoboMan posted:

I can agree with this

i think of orm as a thing you do if database load is not a concern. then it's great because you don't have to write any sql. i will admit this is not very common though

e: it's also good if you hate your dba and will never be on the hook for poor database perfomance

this depends on your orm

hibernate can be ok with even minimal effort

rails and django suck dead weasels through a hose

Asymmetrikon
Oct 30, 2009

I believe you're a big dork!
wish there was a good statement mapper for C#, dapper is ok but not great

Shaggar
Apr 26, 2006

Notorious b.s.d. posted:

this depends on your orm

hibernate can be ok with even minimal effort

rails and django suck dead weasels through a hose

hibernate is bad

Shaggar
Apr 26, 2006

Asymmetrikon posted:

wish there was a good statement mapper for C#, dapper is ok but not great

dapper is not really a statement mapper but its better than EF. there is still the old ibatis.net libs, but they're unmaintained. mybatis+mybatis-spring on java are own zone.

Gul Banana
Nov 28, 2003

bloody are you using asp.net core or the old asp.net? if it's core, just make your project build as an exe and put UseKestrel in the webhostbuilder config in Main.
if it's old-asp you need to use IIS; you can install that on a windows system using the "programs and features" control panel -> "turn windows features on or off". it installs a thing called IIS Manager which you can use for config

HoboMan
Nov 4, 2010

ughhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh

my source control is hosed up and none of my commits yesterday are showing in the history

Finster Dexter
Oct 20, 2014

Beyond is Finster's mad vision of Earth transformed.
holy poo poo nhibernate is REALLY bad

Notorious b.s.d.
Jan 25, 2003

by Reene

Finster Dexter posted:

holy poo poo nhibernate is REALLY bad

nhibernate still exists?

Luigi Thirty
Apr 30, 2006

Emergency confection port.

isn't asp.net core really bad? I forget

I like asp.net and shaggar was right as usual

Asymmetrikon
Oct 30, 2009

I believe you're a big dork!
asp.net core is good

hackbunny
Jul 22, 2007

I haven't been on SA for years but the person who gave me my previous av as a joke felt guilty for doing so and decided to get me a non-shitty av

Finster Dexter posted:

You're usually better off just building a thin repository layer with hardcoded SQL statements (or use a SQL bulder or whatever idc) that returns your data objects.

no you're not. you lose validation, and it's a loving chore to extract data from a record into an object. orms are convenient

disclaimer: I have only ever used orms on small scales. only bad part was never knowing when exactly your data would be saved. also transactions

raminasi
Jan 25, 2005

a last drink with no ice

HoboMan posted:

ughhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh

my source control is hosed up and none of my commits yesterday are showing in the history

if you're using git they're probably in the reflog

Finster Dexter
Oct 20, 2014

Beyond is Finster's mad vision of Earth transformed.

hackbunny posted:

no you're not. you lose validation, and it's a loving chore to extract data from a record into an object. orms are convenient

disclaimer: I have only ever used orms on small scales. only bad part was never knowing when exactly your data would be saved. also transactions

No, you can still do validation at your data layer if you really want to, but part of this goes back to having good db schema. Don't allow nulls if the column shouldn't loving have nulls, etc. But I've done exactly this: repositories with SQL statements, validation via attribute notations provided by MVC/EF. It was insanely easy to set up, and was infinitely better than what we would've had with an ORM.

And said chore of extracting data is what statement mappers would help alleviate. But the thing is, yes it's a chore, but if you know how to DRY you only have to do it once and you're done. And if you're smart about it, you don't even have to edit SQL if you add a column, just add a line of code to your db mapping code.

Finster Dexter
Oct 20, 2014

Beyond is Finster's mad vision of Earth transformed.
loving lol if you think the only good way to validate is with an ORM

Notorious b.s.d.
Jan 25, 2003

by Reene

hackbunny posted:

no you're not. you lose validation, and it's a loving chore to extract data from a record into an object.

statement mappers will typically handle extracting the data for you

writing the statement mapper configuration code sucks though

and, of course, it means hand-writing a lot of sql

Shaggar
Apr 26, 2006

Luigi Thirty posted:

isn't asp.net core really bad? I forget

I like asp.net and shaggar was right as usual

asp.net core is good but its still kind of beta in terms of component availability. In theory the API is finalized so its safe to use

gonadic io
Feb 16, 2011

>>=

Notorious b.s.d. posted:

this depends on your orm

hibernate can be ok with even minimal effort

rails and django suck dead weasels through a hose

Squeryl lol

gonadic io
Feb 16, 2011

>>=
Unrelated: man I love when xml schemas have abbreviated txtSpk names. Gotta save those bytes!

HoboMan
Nov 4, 2010

gonadic io posted:

Unrelated: man I love when xml schemas have abbreviated txtSpk names. Gotta save those bytes!

gotta save space in your verbose as gently caress markup language

NihilCredo
Jun 6, 2011

iram omni possibili modo preme:
plus una illa te diffamabit, quam multæ virtutes commendabunt

Asymmetrikon posted:

wish there was a good statement mapper for C#, dapper is ok but not great

if you're on .net make a separate project for talking to the database (which you should be doing anyways) and use f# type providers

Finster Dexter
Oct 20, 2014

Beyond is Finster's mad vision of Earth transformed.

NihilCredo posted:

if you're on .net make a separate project for talking to the database (which you should be doing anyways) and use f# type providers

Oh hey now you're talkin

Sapozhnik
Jan 2, 2005

Nap Ghost
EclipseLink and JPA2 are quite nice, and the metamodel generator is surprisingly easy to integrate into a Maven build and Java IDE as well.

Most of the time I don't actually model the relationships in the entity classes, I just map the ID fields as IDs. Then I do various criteria query joins in my data service layers. So I guess that means I kinda abuse it as a statement mapper. Attempting to model joins behind the scenes is I think where ORMs start to become a net source of problems.

The criteria API is a bit on the wordy side, but it's also type-safe ...ish. You kinda build an SQL syntax tree by calling a bunch of functions instead of bashing strings together.

If all else fails (read: you need to do a window query) then you can escape to raw SQL too.

Bloody
Mar 3, 2013

this iis poo poo is dumb and annoying

Bloody
Mar 3, 2013

im going to just launch this poo poo from the debugger every time gently caress this. it will only do .net 2.0? what is this garbage

Luigi Thirty
Apr 30, 2006

Emergency confection port.

hell yeah i got 3-dimensional scene rotation and movement actually working this time for reals

i want to figure out texture mapping now but maybe i should actually de-fuckify the player's eye into the scene so it's tied to an object's forward vector instead of existing outside of the simulation

Bloody posted:

im going to just launch this poo poo from the debugger every time gently caress this. it will only do .net 2.0? what is this garbage

??? you're doing something wrong

did you set the app pool to .net framework 4.0?

Bloody
Mar 3, 2013

idk what an app pool even is. i just want to run a website

Adbot
ADBOT LOVES YOU

Bloody
Mar 3, 2013

literally zero parts of this management interface have anything to do with hosting a website

  • Locked thread