Tag: SQL

  • SQLEditor: Compound Foreign Keys

    The newest version of SQLEditor (1.4.4b1) now has support for compound foreign keys. This is something that people have been asking about for a while now, so I’m pleased that it got included.

    There are some things that may need to be improved, but I’m fairly happy with the first revision of this.

    Diagram showing compound foreign key
    Diagram showing compound foreign key

    The compound foreign key object is a new table level object that you can add from the Object menu just like a field or index. Then you drag from the foreign key to the target table. Finally you use the inspector to create pairs of columns to link together.

    When importing from a database SQLEditor will try to create field-to-field links on foreign keys with only 1 pair of columns unless you tell it otherwise. (There is a new preference to do this)

    Support is fairly complete, SQL parsing, database import, database export and SQL export are all available so it should work fairly well. I think the only thing it doesn’t do is auto-create indexes, so you may need to do this by hand on referenced columns (for those databases that need this)

    There is naturally a new inspector palette to go with the table object.

    Compound foreign key inspector
    Compound foreign key inspector

    This allows you to add pairs of columns using the + button at the bottom. Choose your columns using the little popup menus.

    The whole thing is completely new, so please send in your thoughts to the usual address.

    Download SQLEditor 1.4.4b1

    (or enable the “Check for beta versions” preference and then use the check for updates feature)

  • SQLEditor 1.4b2

    Another day, another beta. (Kind of)

    SQLEditor 1.4b2 is now available, which is pretty much bug fixing against 1.4b1.

    There were several issues with 1.4b1 including an annoying bug that would sometimes delete foreign key connectors when you deleted an unrelated table.

    There are some fixes for other bugs which turned up and some improvements to undo/redo, to make it more stable when you undo or redo lots of things, one after the other.

    I’ve also moved SQLEditor to Sparkle. Sparkle replaces an update system that I wrote myself and it should offer better update support as well as a nice html based ‘what’s changed’ window.

    SQLEditor also now tells people that it is a beta and exactly when it will expire. It probably should always have done this, but it does it now, which is probably good.

    There are also some minor fixes to the live source view, so that it changes with the document sql dialect and appears correctly when reopening existing documents.

    [Download] (3.4MB DMG File, changelog)

  • Running Oracle – The Solution

    This follows on from my previous posting. Searching for an Oracle

    This is kind of old news now, because it’s been in use since SQLEditor 1.2 was released. However I though I would explain how I solved the problem that I was having with installing Oracle.

    The problem was that I didn’t have a linux machine with enough memory and at the time, qemu wasn’t really fast enough to run Oracle in a virtual machine.

    The first strategy I used was to upgrade the memory in my linux box (Cetaganda) to 512 MB. This solved the memory problem and meant that the testing could continue.

    Then Parallels Workstation was released, which was able to run Oracle XE in a virtual machine fast enough for regular use. It also uses a different IP address than the host machine, which is useful in itself for testing.

    Parallels is definitely the answer to this problem, I don’t need to switch on another machine, there is no additional noise and the performance is excellent for my purposes. I’m even considering adding the loading of the VM to the unit test setup so it will load automatically before the test cycle starts.

    I’ve also got MySQL and Postgres running inside virtual machines.