code logs -> 2008 -> Wed, 19 Mar 2008< code.20080318.log - code.20080320.log >
--- Log opened Wed Mar 19 00:00:46 2008
01:01 Vornicus [~vorn@ServicesOp.Nightstar.Net] has quit [Ping Timeout]
01:01 Vornotron [~vorn@Admin.Nightstar.Net] has joined #code
01:14 gnolam [lenin@Nightstar-10613.8.5.253.static.se.wasadata.net] has quit [Quit: System crash.]
02:31 ReivUni [~82d94c4d@Nightstar-29731.dsl.in-addr.zen.co.uk] has joined #Code
02:31
< ReivUni>
Quick SQL query, as I don't have a parser with me: Is the following SQL valid, or do I need brackets or something?
02:31
< ReivUni>
SELECT air_name as 'Airline' FROM Airline WHERE air_name like '%Air%'
02:33
< ReivUni>
(I mean on the WHERE line, really. The rest I know to be valid.)
02:36
< Vornotron>
Looks fine. I'd allcaps LIKE
02:36
< Vornotron>
and, uh, do make sure there's a semicolon at the end.
02:37
<@Serah>
That's the only comments I can conjure too.
02:37
<@Serah>
Wow... I actually answered a codelike question seriously.
02:38
< ReivUni>
Thankye.
02:38
< ReivUni>
And now for the Really Annoying bit:
02:39
< ReivUni>
I worked that out five seconds after having to hand in my test paper, where I'd unthinkingly used an " = '%Air%' " in the last moments.
02:40
< ReivUni>
This is a test I would have otherwise gotten 100% on >.<
02:40
< ReivUni>
Worth 1 mark, sure, but it's the principle of the thing~
02:41 * Serah PatPats ReivUni.
02:44
< ReivUni>
I mean, FFS. Five more seconds ;_;
02:58 ReivUni [~82d94c4d@Nightstar-29731.dsl.in-addr.zen.co.uk] has quit [Quit: Classtiem]
04:48 GeekSoldier|bed is now known as GeekSoldier|work
05:27 Vornotron is now known as Vornicus
06:37 Vornicus [~vorn@ServicesOp.Nightstar.Net] has quit [Ping Timeout]
06:42 Vornicus [~vorn@Admin.Nightstar.Net] has joined #code
06:42 mode/#code [+o Vornicus] by ChanServ
07:07 AnnoDomini [AnnoDomini@83.21.75.ns-4557] has joined #Code
07:07 mode/#code [+o AnnoDomini] by ChanServ
08:02
<@McMartin>
Ahahahaha
08:02 * McMartin horribly abuses JOptionPane
08:04 Vornicus is now known as Vornicus-Latens
08:19 GeekSoldier|work [~Rob@91.18.118.ns-4047] has quit [Ping Timeout]
09:10 ASCIISkull [~none@Nightstar-7066.dyn.optonline.net] has joined #code
09:11 AFKSkull [~none@Nightstar-7066.dyn.optonline.net] has quit [Ping Timeout]
09:23
<@jerith>
So, java.sql.ResultSet.
09:24
<@jerith>
Everything that actually gets me to a row returns a boolean.
09:25
<@jerith>
Thus, I need to do this: ResultSet rs = executeStatement("select max(id) from table"); rs.next(); int maxId = rs.getInt(0);
09:26
<@jerith>
Three lines to get a single number out of a query.
09:40
<@McMartin>
Is there a way to get a Result non-set?
09:46 * McMartin also idly finally manages to make Blorple complaint with its own license.
09:47
<@McMartin>
(Which is to say, it now actually has a Menu option to pop up a dialog box that displays its license and (lack of) warranty.)
09:47
<@jerith>
McMartin: All the SQL stuff we use returns a ResultSet.
09:47
<@jerith>
Short of rewriting that, I don't think so.
09:47
<@McMartin>
Mmm. In that case I don't see any other language making that easier.
09:47
<@McMartin>
Well
09:47
<@McMartin>
I guess short of producing a "get{Type}Result" utility function that wraps the lines.
09:48
<@jerith>
A getNextRow() method that returned a ResultSet would be nice.
09:48
<@jerith>
Since I could then chain things.
09:50 * jerith sighs, goe back to writing code instead of grumbling about it.
09:50
<@jerith>
+s
10:05
<@McMartin>
Ugh
10:05
<@McMartin>
Doing proper OS X integration for this while keeping the same binary for all platforms is not going to be easy.
10:07
<@McMartin>
Maybe I can play games with Ant to make it conditional on target.
10:28
<@McMartin>
Also, public service announcement:
10:28
<@McMartin>
"Programmed in (language)" is not a feature.
10:35
<@McMartin>
... other public service announcement
10:35
<@McMartin>
Those of you here that use nfrotz to play IF, I've just released nfrotz 0.3.2. This fixes a memory corruption bug that doesn't seem to show up much, but is sufficiently alarming that it should probably be considered a security issue.
10:35
<@McMartin>
http://www.stanford.edu/~mcmartin/if/nfrotz-0.3.2.tgz has the source - it will appear on the IF-Archive in due course.
11:05
< ASCIISkull>
it can be shorthand for several features, thought
11:05
< ASCIISkull>
*though
12:02 gnolam [lenin@85.8.5.ns-20483] has joined #Code
12:02 mode/#code [+o gnolam] by ChanServ
12:12 gnolam [lenin@85.8.5.ns-20483] has quit [Quit: Reboot]
12:14 gnolam [lenin@85.8.5.ns-20483] has joined #Code
12:14 mode/#code [+o gnolam] by ChanServ
12:19 AnnoDomini [AnnoDomini@83.21.75.ns-4557] has quit [Ping Timeout]
12:20 AnnoDomini [AnnoDomini@83.21.65.ns-3934] has joined #Code
12:20 mode/#code [+o AnnoDomini] by ChanServ
12:52 gnolam [lenin@85.8.5.ns-20483] has quit [Ping Timeout]
12:53 gnolam [lenin@85.8.5.ns-20483] has joined #Code
12:53 mode/#code [+o gnolam] by ChanServ
18:26 GeekSoldier|work [~Rob@91.18.101.ns-2765] has joined #code
18:27 GeekSoldier|work is now known as GeekSoldier
18:40 gnolam [lenin@85.8.5.ns-20483] has quit [Quit: Reboot]
18:42 gnolam [lenin@85.8.5.ns-20483] has joined #Code
18:42 mode/#code [+o gnolam] by ChanServ
18:57 Vornicus-Latens is now known as Vornicus
19:11 gnolam [lenin@85.8.5.ns-20483] has quit [Quit: Reboot]
19:24
<@AnnoDomini>
Hm. In context of a database relation between tables, what does 'dependant' mean?
19:27
<@Vornicus>
A table with a foreign key into another table is dependant on the latter.
19:28
<@AnnoDomini>
So what does that mean?
19:28
<@Vornicus>
It means that the former can't work without the latter in place
19:29
<@AnnoDomini>
So, you can't put a value of the foreign key that doesn't exist as the primary key in the tabel it's dependant on?
19:30
<@Vornicus>
Well, if the primary key is what you're keying on for the foreign key, yes
19:30
<@AnnoDomini>
Cool.
19:30
<@Vornicus>
Really foreign keys can be any candidate key.
19:31 * AnnoDomini puts dependant everywhere. ;p
19:34
<@AnnoDomini>
That might not have been a good idea.
19:39
<@AnnoDomini>
Now I think I might have a workable database model.
19:40
<@AnnoDomini>
So. Anyone here could potentially introduce me to handling a Sybase-generated database with Java?
19:41 * AnnoDomini remembers that jerith had some Java experience, ne?
19:44 * Vornicus has never seen Sybase in use.
19:48 GeekSoldier is now known as GeekSoldier|bed
19:49 GeekSoldier|bed [~Rob@91.18.101.ns-2765] has quit [Quit: Praise "BOB"!]
19:51
<@AnnoDomini>
Well, it was either than or MSAccess.
19:56
<@AnnoDomini>
Heh. I was thinking about how I have about a month to finish this part of the project, and I was reminded that a certain class was not held yet this semester.
19:57
<@AnnoDomini>
Cause? Software has not been installed.
20:10 gnolam [lenin@85.8.5.ns-20483] has joined #Code
20:10 mode/#code [+o gnolam] by ChanServ
20:59
<@jerith>
Evening.
20:59 ASCIISkull [~none@Nightstar-7066.dyn.optonline.net] has quit [Ping Timeout]
21:21
<@AnnoDomini>
Ah, hello.
21:22
<@AnnoDomini>
jerith: Do you have any experience dealing with Sybase databases in Java?
21:22
<@jerith>
No. But if it's standard JDBC, I may be able to help.
21:23
<@AnnoDomini>
Well, SQL grabbed from wikipedia mostly worked, so I suppose it's some sort of standard.
21:23
<@AnnoDomini>
I kinda need an introduction to the whole thing.
21:24
<@jerith>
Do you know SQL?
21:25
<@AnnoDomini>
What do you mean by 'know SQL'?
21:25
<@AnnoDomini>
I know how to do most simple queries and how to insert stuff into tables, for the most part.
21:26
<@jerith>
Ah. My knowledge goes a bit beyond that, but not much.
21:26
<@AnnoDomini>
Create tables, too, but I don't do that much, what with PowerDesigner doing that for me.
21:27
<@AnnoDomini>
SQL is easy enough to parse by humans, if said humans know English. :)
21:27
<@AnnoDomini>
(Reminds me of that dude who sat next to me who didn't have the foggiest what the words meant.)
21:29
<@jerith>
We have queries that go on for pages.
21:30
<@ToxicFrog>
Yeah. "select foo from bar where baz" is easy. Twenty lines of joined queries is not.
21:32
<@jerith>
Especially when said query suddenly takes 15 minutes to run and needs to be fixed *right* *now*.
22:07 Vornicus [~vorn@Admin.Nightstar.Net] has quit [Ping Timeout]
22:11 Vornicus [~vorn@Admin.Nightstar.Net] has joined #code
22:11 mode/#code [+o Vornicus] by ChanServ
22:15 ASCIISkull [~none@Nightstar-7066.dyn.optonline.net] has joined #code
22:15 ASCIISkull is now known as AFKSkull
23:01 gnolam [lenin@85.8.5.ns-20483] has quit [Ping Timeout]
23:01 gnolam [lenin@Nightstar-10613.8.5.253.static.se.wasadata.net] has joined #Code
23:01 mode/#code [+o gnolam] by ChanServ
--- Log closed Thu Mar 20 00:00:56 2008
code logs -> 2008 -> Wed, 19 Mar 2008< code.20080318.log - code.20080320.log >