« first day (1619 days earlier)      last day (3370 days later) » 

user55340
12:43 AM
@SimonAndréForsberg I thought the "don't trigger on questions or answers" would have caught that?
 
user55340
2
A: New SE Chat Bot feature for identifying when Programmers is mentioned on StackOverflow

MichaelTA filter that might remove some additional false positives is to remove things where the comment contains a link to a question or an answer (or help page?). For example this one. Such links are not likely to be someone saying "go post there" but rather the cross site dup style "this has been ...

 
user55340
If the link is of the format: programmers.stackexchange.com/[aq]/\d+ its a link to a direct question or answer and unlikely to be a "try asking there" comment.
 
user55340
I want to say that this is the first time I've seen a relatively new user on P.SE come back to a question that they asked and do a good self answered question.
 
user55340
1
A: Enforcing manual inclusion of a specific header file (banned.h)

AHelpsAfter much debate, we found a method that we like, but it involved other substantial changes to the project. We turned on pre-compiled headers. Within the pre-compiled header, we first include any and all system headers (and other third-party library headers) that are not compliant with banned.h,...

 
user55340
2:02 AM
@JörgWMittag Perl6 promises the possibility of auto threading in its junctions: en.wikipedia.org/wiki/Perl_6#Autothreading
 
user55340
> Junctions are unordered; `1|2|3` and `3|2|1` represent the same value. This lack of ordering means that the Perl 6 compiler can choose to evaluate junctive expressions in parallel. For instance, the code:

if $string ~~ all(@list_of_regexes) {
. . .
}

would indicate to the compiler that all matches of a string against a list of regexes can be executed in parallel, possibly in separate threads. This feature is dubbed "autothreading". The parallelization of autothreading is not yet implemented in any Perl 6 compiler.
 
2:47 AM
@MichaelT That would be another example of an explicitly parallel data structure. Something similar in Scala would probably be listOfRegexes.par.forall(…)
 
user55340
@JörgWMittag Yep. Just another for your set of examples and that even with things that are that 'easy' - it is still hard to do (as evidenced by it not being part of any Perl6 compiler yet).
 
user41796
0
Q: Update "Introducing Programmers" blog to reflect site scope change

GlenH7In the Introducing programmers.stackexchange.com blog post, Jeff announces our site with great fanfare. And while I'm all for promoting our site, there are a few problems with that post that I think are creating recurring issues for us. First off, there's a link to the FAQ which now redirects t...

 
user41796
Stupid one-boxing...
 
user55340
@GlenH7 Just saw that show up on Meta.
 
user41796
Not sure it'll go anywhere, but I figured I had to at least try
 
user55340
2:54 AM
in Game Development, 2 mins ago, by MichaelT
Just a heads up that a question showed up on meta.Programmers.SE that I'm suggesting to send over your way (as in "ask in chat") - any regulars here may wish to comment on it and correct me (please do) about the scope of chat here and GameDev itself.
 
user41796
@JörgWMittag - great comment, btw, on the tail call optimization vs. TRE question. It's been re-opened after I flagged it.
 
user41796
@MichaelT I was tempted to suggest world building to that meta question, but I don't think they were wanting to go that route
 
user55340
The "ask in chat" is probably best... though I also wanted to have their chat regulars comment on it if I was off base.
 
user41796
wise approach
 
user55340
At worst, he'll get told in chat that I was wrong and it wasn't the place. Rooms are even more different than sites, though often can handle the off topic more eaislly than sites can.
 
3:03 AM
Hey guys, whats a common flat file noSQL db these days for node.js? I am learning node.js and would like to use a flat file to start my project instead of a full featured db.
 
user55340
@masfenix flat? or nearly flat? The later - sqllite
 
sqlite is what I was thinking off, but that is relational, no? I'd have to setup tables and stuff?
my project will require just one table with maybe 10 columns
 
user55340
True... it is relational. You could always fire up a Couch instance if you wanted.
 
Hmm okay.
What do you think of
 
user55340
3:04 AM
I'd go with sqlite in that case... you could always make a KVP database out of it if you wanted to.
 
user55340
Its common, its everywhere, you can use it for other things.
 
Sorry "KVP">
 
user55340
Key Value Pair
 
user55340
A name–value pair, key–value pair, field–value pair or attribute–value pair is a fundamental data representation in computing systems and applications. Designers often desire an open-ended data structure that allows for future extension without modifying existing code or data. In such situations, all or part of the data model may be expressed as a collection of tuples <attribute name, value>; each element is an attribute–value pair. Depending on the particular application and the implementation chosen by programmers, attribute names may or may not be unique. Some of the applications where information...
 
3:05 AM
I mean, memoria looks like what I want.. but I am not sure how popular, updated t is.
 
user55340
One table, two columns. Key and value.
 
okay i'll go for sqlite.
 
user55340
You could even 'abuse' it with sticking JSON in the value if you wanted to and pretend its a NoSQL database.
 
yeah, actually do you remember helping me out with my "calendar" project?
 
user55340
The date range problem (thinking back - the last month has been quite busy for me)
 
3:07 AM
Nah its okay, so I've gone ahead andinstalled sqlite
I guess I will stick with that
 
user55340
(aside: if you do play with date ranges much... you might want to look in the direction of Postgres - it has a really nice range function for dates: postgresql.org/docs/9.2/static/rangetypes.html )
 
user55340
> CREATE TABLE reservation (room int, during tsrange);
INSERT INTO reservation VALUES
(1108, '[2010-01-01 14:30, 2010-01-01 15:30)');

-- Containment
SELECT int4range(10, 20) @> 3;

-- Overlaps
SELECT numrange(11.1, 22.2) && numrange(20.0, 30.0);

-- Extract the upper bound
SELECT upper(int8range(15, 25));

-- Compute the intersection
SELECT int4range(10, 20) * int4range(15, 25);

-- Is the range empty?
SELECT isempty(numrange(1, 5));
 
user55340
That sort of thing is rather nice when you're working with dates and reservations.
 
my project will have a form in which users enter details (fields will correspond to the ICS calendar protocol fields). Then other users can request a dynamic ics file to subscribe too.
 
user55340
(ahh yes! ICS!)
 
3:09 AM
yeah hehe
 
user55340
Ok, its all coming back to me now.
 
so, do you think it will be better to go postgre?
 
user55340
For that, probably not. Though if you are doing things like room reservations and the like.. you might want to keep postgres in the back of your mind as "it might be worth it to become familiar with it with a toy project"
 
I mean memoria kinda looks like what I want
okay, well its not reservations.. its essentially a webapp for my university department to enter in details for specific events
 
user55340
At the end of the day, nearly any database can do what you want it to for any project. Its a matter of how far you want to force it to do it if its not "perfectly" aligned with it.
 
3:11 AM
and our students can subscribe to it.
okay, thanks.
I think I am gonna go npmjs.com/package/memoria
simply because it looks very easy to use and retrieve data. Plus maybe I'll learn something new.
 
user55340
I could just as 'easilly' do that in Couch, or Mongo or sqllite or Oracle or MySQL or Postgres... or even berkely db.
 
user55340
Now, when you want to start doing other things with it... then you might start wondering about "well, maybe a document oriented database would work better" or "I really do want relations in there for certain queries..." and it biases to one direction or the other.
 
fair enough. I do have plans to expand it to the entire university
and than to other universities :p
 
user55340
Do you start getting relations between students and departments and "I want to subscribe to events from "all students majoring in Computer Science and Engineering""? That's a relation...
 
user55340
One of those 'under the hood' things... iTunes uses sqlite. Smart play lists? Those are SQL queries with joins and where clauses.
 
3:15 AM
Yes, students will be able to filter out events they don't want. An art student may not want seminars in physics. But the way I was thinking is that my data will look like this { dept: physics, type = seminar, ICSfield1, ICSfield2, ... }
and so when the filtering happens, I'd just "select * from table where dept = physics"
but using NoSQL lol
 
user55340
You might want to see how it works in each database to see which one you like and how it maps to how you are thinking about the problem. Just toss one in Couch (I like it), one in sqllite and one in memoria.
 
user55340
Its easy to do each at this point in the project.
 
user55340
2
Q: Couch DB filter by key and sort by another field

DilshanIn couchdb I need to filter by key and which is done like this. { "_id": "_design/test", "_rev": "6-cef7048c4fadf0daa67005fefe", "language": "javascript", "views": { "all": { "map": "function(doc) { if (doc.blogId) {emit(doc.key, doc);} }" } } } However ...

 
What do you mean, use node.js to connect to three different databases and "insert" into all of them? Just to see what I like?
 
user55340
Use NodeJS. Write the application (database layer) three times - once for each database. See which one works the way you want it to.
 
user55340
3:18 AM
Learn how to use each database - the early brainstorming / prototyping is the best time to do it before you go too far down a path and get stuck with one approach.
 
Oh okay, that sounds like a good plan. Now if I can figure out how to separate the database layer
thanks for your help
I am just going over the template express gives me
just to get an idea how the organization
 
user55340
(neat bit with couch - no, its not a file based one - its another database all together) is that its a webserver of its own.
 
user55340
You query / update it via REST.
 
if I can ask you another question: when users do submit the form, whats the best way to get that information back to the server? querystrings?
ahh I see, i'll look into it and set it up as a DAL.
 
user55340
Most often, it wold be post.
 
3:20 AM
Ah yes, that's what I meant. Okay and I'll obviously have to watch out for XSS injection
 
user55340
Unless its a small form.. even then. Post and redirect is a well known web pattern for avoiding multiple submissions.
 
user55340
Post/Redirect/Get (PRG) is a web development design pattern that prevents some duplicate form submissions, creating a more intuitive interface for user agents (users). PRG supports bookmarks and the refresh button in a predictable way that does not create duplicate form submissions. == Duplicate form submissions == When a web form is submitted to a server through an HTTP POST request, a web user that attempts to refresh the server response in certain user agents can cause the contents of the original HTTP POST request to be resubmitted, possibly causing undesired results, such as a duplicate web...
 
user55340
Apache CouchDB, commonly referred to as CouchDB, is an open source database that focuses on ease of use and on being "a database that completely embraces the web". It is a document-oriented NoSQL database that uses JSON to store data, JavaScript as its query language using MapReduce, and HTTP for an API. One of its distinguishing features is multi-master replication. CouchDB was first released in 2005 and later became an Apache project in 2008. Unlike in a relational database, CouchDB does not store data and relationships in tables. Instead, each database is a collection of independent documents...
 
user55340
@masfenix I used couch at my former employer... the javascript query language for views, filters, and maps (internal to Couch) played to the strong point of web developers without needing much in the way of DBAs. The web/rest aspect of it made it quite easy to work with also for the node half of the house (or so I'm told - though they also had Mongo on one spot).
 
Hmm interesting. So I'll go ahead and read about CouchDB as well. Maybe an overkill for this, but seems like everyone is using it these days
 
user55340
3:26 AM
Its also interesting - you could even expose the database for others to run queries against (set up the access for that user to read only) without much impact... its a rather study server.
 
user55340
(written in erlang)
 
user55340
Another approach to look at - go with one of the databases thats associated with compute clouds.
 
user55340
Amazon SimpleDB is a distributed database written in Erlang by Amazon.com. It is used as a web service in concert with Amazon Elastic Compute Cloud (EC2) and Amazon S3 and is part of Amazon Web Services. It was announced on December 13, 2007. As with EC2 and S3, Amazon charges fees for SimpleDB storage, transfer, and throughput over the Internet. On December 1, 2008, Amazon introduced new pricing with Free Tier for 1 GB of data & 25 machine hours. Transfer to other Amazon Web Services is free of charge. == Limitations == SimpleDB provides eventual consistency, which is a weaker form of consistency...
 
I am a MS fan, so I was thinking if (and when) my project gets big, I can use Azure to scale up
 
user55340
That points you in the direction of: azure.microsoft.com/en-us/services/sql-database
 
3:30 AM
They also have mongodb
and a big platform for node.js
infact I am using their free website (165MB/day of data)
as a testing stage
 
user55340
Mongo is a well known database... particularly for the node types (part of the MEAN stack)
 
user55340
MEAN refers to first letters of the four components of a free and open-source solution stack for building dynamic web sites. MEAN is a full-stack JavaScript platform designed for web applications. Valeri Karpov was a MongoDB developer at that time, who coined the MEAN stack term, and tells about it in one of his blog posts. The components of the MEAN stack are as follows: MongoDB, a NoSQL database; Express.js, a web applications framework; Angular.js, a JavaScript MVC framework for web apps; Node.js, a software platform for scalable server-side and networking applications. == Logos == The initial...
 
user55340
If you work with that stack, it should be easier for other node coders to pick it up and work with it too because its a relatively well known set of technologies.
 
3:47 AM
Do you think its a good idea
 
user55340
MEAN? or Node in general?
 
to create one column called "icsdata" and in that field I store a json { VTIME = "", DATE = "" }
or split up the ICS columns into their respective fields.
 
user55340
Split it up unless you really have a reason for it otherwise.
 
I don't think i'll ever have to join/intersect using those columns, so may as well store it as one field.
Oh okay haha
 
user55340
Unless you are working with something that can look into JSON its an opaque string to most databses.
 
user55340
3:50 AM
Its also a matter of how much you are stuffing into an index, if you want to be able to query on them later, being able to store then in a more natural type...
 
You know what I am actually gonna just go ahead and use MongoDB
 
user55340
The 'stuff it all in one column' was more a "if you want to pretend you are working with a very simplistic NoSQL database" type mindset.
 
user55340
Not a good idea - more of a "you can push any database to be any other type of database if you push hard enough"
 
Actually I cant really decide. I really just want to go with a flat file NoSQL database that has Mongoose as its ORM. Too much to ask for?
Do you have any tutorials on how to keep the DAL separate incase I decide to change later on?
I think I found it:
 
 
2 hours later…
6:04 AM
Well @dk... I did check but I did not copy paste... Retyped here and hence typing mistake. Anyways... Some good points by you are probably genuine... But do you want me to explain what promises are in an answer. Also... Stackoverflow is a place for programmers to get help in problems... Biggest part of that would be helping them in understanding the mistake in their code... Not just how to fix it... And neither by providing a functionally pure, idiomatic scala solution. — Sarvesh Kumar Singh 1 min ago
 
 
4 hours later…
10:28 AM
@MichaelT if it only contained the link, it wouldn't have posted it here, but it also contained "on programmers.SE"
Your site is quite hard to make a good comment-filter for
@MichaelT for example, this comment was not posted here, only in Duga's Playground:
 
10:50 AM
Hi! Can YOU give me some resume critique? I'm applying for several summer internships on both big tech companies and startups I find interesting. Here's the pdf: dl.dropboxusercontent.com/u/902439/…
 
 
4 hours later…
user41796
2:29 PM
I put too much effort into this answer...
 
user41796
-1
Q: Accuracy proportional to size

user3525258I have lists of data I'm trying to organize where the list with the least variation/most precision/closest to the average and most amount of data is most highly rated. Some of the lists are like 2000 numbers long and others only have 1 number. Obviously the arithmetic mean of a list with one num...

 
user41796
@SimonAndréForsberg We're glad to give you a challenge then!
 
@GlenH7 ha - ha - ha.
 
user41796
'cause you had nothing better to do, right?
 
I will keep the current filter for a couple of days and then we will see what to do
I'm a programmer, I always have things to do.
3
 
user41796
2:31 PM
Sounds good. And thank you again for all of your efforts with this. It's appreciated. False positives are a minor nuisance in comparison to being able to stop the bad site recommendations.
4
 
Glad to hear that :)
 
I'm also glad to hear that!
 
I'm quite happy with the newly applied filter so far, @Duga has caught several irrelevant comments, and no real-positives have been filtered away.
 
user55340
2:52 PM
Something fun for engineers and the Raspberry Pi - photographing the board with a flash can reboot it. raspberrypi.org/forums/viewtopic.php?f=28&t=99042 (Gets fun on page 2 when the oscilloscopes come out).
 
user55340
Note forum is getting /.'ed at the moment.... So...
 
6:07 PM
Yes, it's called a "big-ass cache." Not everything has to have a name. Can you be more specific about "new cache algorithms become available?" We prefer to answer questions about specific topics here, rather than naming things and sending people off to Google. — Robert Harvey 1 hour ago
Too harsh?
 
 
4 hours later…
10:06 PM
@jww questions like this are typically closed as too broad at Programmers. It's also unclear what help asker needs. — gnat 1 min ago
 
@Duga missed one!
in Duga's Playground, 12 mins ago, by Duga
This does not seem like a bad question, but it might be kind of broad for Stack Overflow. Programmers Stack Exchange might be a better place because they field higher level design questions, and this seems to fall into that category. — jww 26 secs ago
gnat got to it even without @Duga though
 

« first day (1619 days earlier)      last day (3370 days later) »