Skip to main content
Chris Cirefice's user avatar
Chris Cirefice's user avatar
Chris Cirefice's user avatar
Chris Cirefice
  • Member for 12 years
  • Last seen more than a month ago
comment
Is ORM a bad tool for tree-like DB structures?
@DavidPacker Ah, the missing letter threw me off.
comment
Is ORM a bad tool for tree-like DB structures?
@DavidPacker I understood 50% of those acronyms - can you elaborate?
comment
Is ORM a bad tool for tree-like DB structures?
I've never used nHibernate, but I have used some such as Rails' ActiveRecord, OrmLite (Java), and ActiveJdbc (Java). Each of these handles executing raw SQL differently, e.g. ActiveRecord makes it really easy, and OrmLite made it really difficult. ActiveRecord has been in development for years and years, so surely that has something to do with it. All these little nuances are part of feasibility testing, but sometimes you miss the little things that come back to bite you later...
comment
Is ORM a bad tool for tree-like DB structures?
It should be noted that, in lots of ORMs (at least every one that I've used), you can write and execute raw SQL. Therefore, if the ORM does not satisfy some constraint well, you can always resort to doing it with native SQL, while simultaneously reducing the 'boilerplate' operations of SELECT * FROM some_table WHERE x = whatever that are extremely common. Hierarchical structures are handled well in some ORMs, and terribly in others, so this type of consideration should be researched before deciding to forgo ORMs entirely.
comment
REST API caching strategy for collection of records
@LaurentS That sounds like a good plan! And if you only have a daily update to do, then the query method is the wholly obvious choice compared to websockets (which are designed for a 'live' type of experience).
Loading…
comment
REST API caching strategy for collection of records
@LaurentS Everyone will understand a query parameter; very few people will (immediately) understand bizarre non-conforming use of a standard header. The less you can make people scratch their heads when reading your code, the better. Whoever has to maintain it later will thank you for it.
accepted
awarded
asked
Loading…
comment
At what point is brevity no longer a virtue?
@FrustratedWithFormsDesigner I would even go a step further and wrap the conditional check in parentheses.
revised
Loading…
comment
From web database (PostgreSQL) to mobile (SQLite)
@RobertHarvey I was asking if my approach for doing the task - getting data from PostgreSQL on the web into a local SQLite - was appropriate, or if there was a better way of doing it (e.g. through dumping the database through psql or something similar). I'm sorry if that wasn't very well-said.
revised
Loading…
comment
From web database (PostgreSQL) to mobile (SQLite)
@yorodm I would agree with that, but that's not what the boss wants to do :)
accepted
Loading…
comment
Is saving disk space a valid reason to forgo migrating to a standard text format (e.g. JSON)?
@adeady That would definitely make sense for a very large system, but ours is actually pretty tiny - only about 100 MB of data total, so the complexity there wouldn't be worth it.
comment
Is saving disk space a valid reason to forgo migrating to a standard text format (e.g. JSON)?
@svidgen Hm, I'm having a hard time coming up with a good example. These aren't just tags, like you might think of on a StackExchange question (a limited set of data that can be expressed relationally). Let's take a natura llanguage word for example. If I'm trying to model a word, it might have an id, word, and tag field (tag being JSON). A word and its translations can be modeled relationally, but semantic information about a word varies across languages. E.g. a French word might have gender and number, English would not. And there are 6000+ varying languages. Does that help?
revised
Is saving disk space a valid reason to forgo migrating to a standard text format (e.g. JSON)?
Added clarification about what is structured and what is not
Loading…
1
3 4
5
6 7
19