The web in a box - a next generation web framework for the Perl programming language

IRC log for #mojo, 2018-01-28

| Channels | #mojo index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:05 Leffe joined #mojo
00:13 good_news_everyon joined #mojo
00:13 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vNDIn
00:13 good_news_everyon mojo-pg/master 37042c1 Sebastian Riedel: use flags for the join type
00:13 good_news_everyon left #mojo
00:15 sri yea, i think i like that
00:26 Leffe joined #mojo
00:28 mishanti1 14 hours of tearing Moose out a legacy application. Finally done. Night everyone!
00:40 Seth joined #mojo
01:08 aborazmeh joined #mojo
01:21 good_news_everyon joined #mojo
01:21 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vNDqE
01:21 good_news_everyon mojo-pg/master c2db7d1 Sebastian Riedel: better error messages
01:21 good_news_everyon left #mojo
01:26 good_news_everyon joined #mojo
01:26 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vNDqF
01:26 good_news_everyon mojo-pg/master a688169 Sebastian Riedel: show method signatures
01:26 good_news_everyon left #mojo
01:29 good_news_everyon joined #mojo
01:29 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vNDqp
01:29 good_news_everyon mojo-pg/master d548d0a Sebastian Riedel: the example should be enough
01:29 good_news_everyon left #mojo
01:34 good_news_everyon joined #mojo
01:34 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vNDmk
01:34 good_news_everyon mojo-pg/master b8291b3 Sebastian Riedel: complain about undefined values
01:34 good_news_everyon left #mojo
01:36 good_news_everyon joined #mojo
01:36 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vNDmY
01:36 good_news_everyon mojo-pg/master 75e4248 Sebastian Riedel: fix typo in example
01:36 good_news_everyon left #mojo
01:45 tchaves joined #mojo
01:49 good_news_everyon joined #mojo
01:49 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vNDmM
01:49 good_news_everyon mojo-pg/master 13ac0fa Sebastian Riedel: more tests and examples
01:49 good_news_everyon left #mojo
05:04 dboehmer joined #mojo
05:21 aborazmeh joined #mojo
06:30 Vandal joined #mojo
08:41 bianca joined #mojo
10:21 dotan_convos joined #mojo
10:23 trone joined #mojo
11:16 karjala_ joined #mojo
11:22 sri hmm, i also want column aliases to be easier, and stuff like extract(...)
11:24 sri that's actually annoying
11:33 bianca joined #mojo
11:36 itaipu joined #mojo
11:39 * sri opens a pull request for another extension hook https://github.com/dbsrgits/sql-abstract/pull/13
11:41 sri once that is applied i will at least support ->select('foo', ['bar', \'extract(...) as time', ...], ...)
11:43 sri and i guess ->select('foo', \['? as passthrough', 'some value'], ...], ...)
11:44 sri ->select('foo', [\['? as passthrough', 'some value'], ...], ...)
11:50 skaji joined #mojo
11:52 skaji joined #mojo
11:59 sri another interesting idea from twitter, $abstract->insert('some_table' [{foo => 'bar'}, {foo => 'baz'}])
12:01 sri think that might actually be doable by hooking into _insert_ARRAYREF
12:10 sri and i really like what i ended up with for joins
12:10 sri $db->select(['foo', [-left => 'bar', foo_id => 'id']]);
12:10 sri select * from foo left join bar on (bar.foo_id = foo.id)
12:16 sri re select fields, maybe i'll also do simple aliases
12:16 sri ->select('foo', [['bar', 'a'], ['baz', 'b']])
12:16 sri select bar as a, baz as b from foo
12:18 sri ->select(['foo', [-left => 'bar', foo_id => 'id']], [['bar.thing', 'thing'], ['foo.thing', 'other_thing']])
12:18 sri that would seem rather useful
12:43 good_news_everyon joined #mojo
12:43 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vND21
12:43 good_news_everyon mojo-pg/master 842b386 Sebastian Riedel: add support for "GROUP BY" with "HAVING"
12:43 good_news_everyon left #mojo
13:10 brunoramos joined #mojo
13:22 bianca joined #mojo
13:46 trone_ joined #mojo
13:50 bianca joined #mojo
13:51 mtths joined #mojo
14:01 aborazmeh joined #mojo
14:53 itaipu joined #mojo
15:00 good_news_everyon joined #mojo
15:00 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vNDKh
15:00 good_news_everyon mojo-pg/master 71c592e Sebastian Riedel: add support for field aliases to select and select_p methods in Mojo::Pg::Database
15:00 good_news_everyon left #mojo
15:01 sri that should take care of the most common cases http://mojolicious.org/perldoc/SQL/Abstract/Pg#AS
15:01 sri i was thinking about aliases for joined field specifically
15:01 sri **fields
15:02 sri ->select(['foo', [-left => 'bar', foo_id => 'id']], [\'foo.*', ['bar.baz' => 'yada']]);
15:03 vicash joined #mojo
15:11 good_news_everyon joined #mojo
15:11 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vND6W
15:11 good_news_everyon mojo-pg/master 182a798 Sebastian Riedel: change order of documentation sections
15:11 good_news_everyon left #mojo
15:14 berov joined #mojo
15:14 good_news_everyon joined #mojo
15:14 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vND60
15:14 good_news_everyon mojo-pg/master e221f63 Sebastian Riedel: more consistent synopsis examples
15:14 good_news_everyon left #mojo
15:20 bianca joined #mojo
15:32 good_news_everyon joined #mojo
15:32 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vNDi2
15:32 good_news_everyon mojo-pg/master 67d9d63 Sebastian Riedel: more consistent error messages
15:32 good_news_everyon left #mojo
15:33 sri think that's all features i want for now
16:00 sh14 joined #mojo
16:15 kes joined #mojo
16:32 dod joined #mojo
16:34 anony joined #mojo
16:38 dod joined #mojo
17:01 jamesaxl joined #mojo
17:04 berov sri: nice features. Congatulations!
17:18 ChmEarl joined #mojo
17:18 kes Hi. Sometimes we want to generate input fields without names. Is it supported by Mojolicious?
17:20 kes %= check_box undef
17:23 good_news_everyon joined #mojo
17:23 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vNDSk
17:23 good_news_everyon mojo-pg/master 2158464 Sebastian Riedel: show how to combine different field types
17:23 good_news_everyon left #mojo
17:49 Grinnz hmm. joins are often not made to the immediately preceding table; is it possible to join to a particular table without going to literal sql?
17:51 sri actually it only works for the first table
17:51 sri the assumption is that 90% of the time you only select from one table and join a few other tables
17:52 Grinnz well that would be like 10% of my work queries, lol
17:52 sri it's 100% of my work queries
17:52 sri you're welcome to propose more features of course
17:53 sri also, you might want to say it now if you think some of the features are a bad idea and shouldn't be released
17:54 Grinnz imo the convenient syntax needs to be able to include table identifiers to be useful
17:54 sri btw. the join feature is modeled after sequel https://github.com/jeremyevans/sequel#joining-tables
17:54 Grinnz but it's not like using literal sql there is that hard
17:55 sri well, that is trivial to add
17:55 sri ->select(['foo', ['bar', 'bar.foo_is' => 'foo.id']])
17:56 sri and then match on the separator
17:56 Grinnz makes sense to me
18:06 good_news_everyon joined #mojo
18:06 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vNDH7
18:06 good_news_everyon mojo-pg/master 9a39471 Sebastian Riedel: allow table names to be specified for join conditions
18:06 good_news_everyon left #mojo
18:06 sri Grinnz: there you go
18:07 Grinnz cool!
18:09 dod joined #mojo
18:12 Grinnz only other thing i can think of that would be useful is table aliases, SQL::Abstract doesn't do that normally does it?
18:13 Grinnz since it doesnt have joins its not really needed, but with joins the select and where clauses will need to reference them more often
18:16 sri two element arrays are still available
18:16 sri three and four element are joins
18:16 dod1 joined #mojo
18:16 sri ->select([[foo => 'f']])
18:17 sri not gonna do that just yet though
18:17 sri but it's an option for the future if it does become a problem
18:18 sri ->select([[foo => 'f'], [-left => 'bar', 'f.id' => 'bar.id']])
18:19 sri i cared more about column aliasing because that's useful for getting the result hash into the right format
18:19 Grinnz sure
18:21 jamesaxl hello
18:22 jamesaxl If I am working with mojo and reactjs. I it is no need to render html with mojo, it is enough to get json data and render it with reactjs
18:23 Grinnz for ajax queries, sure, that's the proper approach
18:24 jamesaxl Grinnz: thank you
18:48 good_news_everyon joined #mojo
18:48 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vND5o
18:48 good_news_everyon mojo-pg/master 42f7e11 Sebastian Riedel: more consistent error messages
18:48 good_news_everyon left #mojo
18:51 Leffe joined #mojo
19:05 good_news_everyon joined #mojo
19:05 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vNDdE
19:05 good_news_everyon mojo-pg/master 7532eac Sebastian Riedel: bump version
19:05 good_news_everyon left #mojo
19:06 sri we'll do it live
19:14 bianca joined #mojo
19:16 ghenry joined #mojo
19:24 sri perhaps we should have a method chain syntax for selects too
19:27 Grinnz i think that would be neat, but not sure if it would be appropriate to push into SQL::Abstract
19:27 sri $pg->db->table('foo')->select('foo', 'bar')->where(foo => 'bar')->...
19:28 sri no, it would just use SQL::Abstract to generate the SQL
19:28 pink_mist time to make Mojo::SQL instead of SQL::Abstract? :P
19:28 sri it's just syntax sugar around SQLA
21:38 dotan_convos joined #mojo
21:57 stu joined #mojo
22:07 mib_ur4ba3 joined #mojo
22:10 itaipu joined #mojo
22:29 good_news_everyon joined #mojo
22:29 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vNyf8
22:29 good_news_everyon mojo-pg/master 8112c33 Sebastian Riedel: move example
22:29 good_news_everyon left #mojo
22:34 good_news_everyon joined #mojo
22:34 good_news_everyon [mojo-pg] kraih pushed 1 new commit to master: https://git.io/vNyfi
22:34 good_news_everyon mojo-pg/master d07e318 Sebastian Riedel: split examples into two sections
22:34 good_news_everyon left #mojo
23:26 dotan_convos joined #mojo

| Channels | #mojo index | Today | | Search | Google Search | Plain-Text | summary