RE: [OpenMap Users] DBF and Shape

From: Bart Jourquin <bart.jourquin_at_fucam.ac.be>
Date: Thu, 03 Mar 2005 18:26:07 +0100

Hi Tobias,

you could effectively write a new class that extends EsriPlugin and
write a query method in which you use the result of your query to set
the visibility of your objects. The method should implement all the
needed JDBC stuff, but it is not very complicated. The only difficulty
is to find the right link between the output of your query and the
relevant records. I'm not sure you can use something like "select recno
() ..." with the dbf-jdbc driver I've mentioned.

Bart


Le jeudi 03 mars 2005 à 16:04 +0100, Gorgs, Tobias a écrit :

> Hi Ruben,
>
> you wrote:
> "However, you can extend EsriPlugin to perform JDBC/SQL queries on the
> DBF tables using an appropriate JDBC driver."
>
> I'm a newbie to Java and OpenMap and have no idea how to do this.
> I tried this:
>
> EsriPlugIn epi = new EsriPlugIn("", dbf.toURL(), shp.toURL(),
> shx.toURL());
> PlugInLayer pil = new PlugInLayer();
> DbfTableModel dtm = epi.getModel();
> epi.query ("SELECT * FROM dtm WHERE ..."); //SQL-Statement
> pil.setPlugIn(epi);
>
> Do you think this is the right idea to solve the problem. Any other
> ideas?
> Thanks a lot.
>
> Regards,
> Tobias
>
>
>
>
>
>
> -----Original Message-----
> From: owner-openmap-users_at_bbn.com [mailto:owner-openmap-
> users_at_bbn.com]On Behalf Of Bart Jourquin
> Sent: Monday, February 28, 2005 3:17 PM
> To: Rubén Ruiz
> Cc: OpenMap
> Subject: RE: [OpenMap Users] DBF and Shape
>
>
> Hi Tobias and Ruben,
>
> Having the row number is not enough if you don't know which
> rows you need :-)
>
> Actually, a complete query mechanism is not (yet?) implemented
> in OpenMap.
>
> However, you can extend EsriPlugin to perform JDBC/SQL queries
> on the DBF tables using an appropriate JDBC driver.
>
> Unfortunately, unless you only work with Windows, for which
> you can use the free jdbc/odbc bridge, there is no free jdbc
> driver available. I think the most easy to use solution can be
> found on http://www.hxtt.net/
>
> You also can extend the esri layer/plugin to use full fledge
> sql engines, but this requires the tables to be imported in
> the database. A "lighter" solution is to use hsqldb
> (hsqldb.sf.net) which can create "memory" databases on the
> fly... I think that Don has investigated this particular
> approach.
>
> Best regards,
>
> Bart
>
>
> Le vendredi 25 février 2005 à 14:52 +0100, Rubén Ruiz a
> écrit :
>
> > Hi Tobias,
> > You can read the DBF files and with the AppObject in the OmGraphics, set the
> > visibility. You may use DbfInputStream and DbfTableModel. The AppObject of
> > an Omgraphic contains an Integer object which is the row number from the
> > associated dbf.
> >
> > Hope this helps,
> > Rubén Ruiz.
> >
> > -----Mensaje original-----
> > De: owner-openmap-users_at_bbn.com [mailto:owner-openmap-users_at_bbn.com] En
> > nombre de Gorgs, Tobias
> > Enviado el: viernes, 25 de febrero de 2005 8:21
> > Para: 'openmap-users_at_bbn.com'
> > Asunto: [OpenMap Users] DBF and Shape
> >
> > Hi all,
> >
> > is it possible to query a DBF-File (perhaps with a SQL-statement) and show
> > only part of the Shape-Layer through that? Where do I have to look in the
> > API for this. I found something about the DbfInputStream in the API but
> > there is nothing about to query it.
> >
> > Any ideas?
> >
> > Thanks a lot.
> > Tobi
> >
> > --
> > [To unsubscribe to this list send an email to "majdart_at_bbn.com"
> > with the following text in the BODY of the message "unsubscribe
> > openmap-users"]
> >
> >
> >
> > --
> > [To unsubscribe to this list send an email to "majdart_at_bbn.com"
> > with the following text in the BODY of the message "unsubscribe openmap-users"]
>
> ---
> Prof Dr Bart Jourquin
> F.U.Ca.M. - G.T.M.
> Chaussée de Binche, 151a, B7000 Mons (Belgium)
> Tel. : +32 65 323293, Fax. : +32 65 315691
> http://www.fucam.ac.be/jourquin

---
Prof Dr Bart Jourquin
F.U.Ca.M. - G.T.M.
Chaussée de Binche, 151a, B7000 Mons (Belgium)
Tel. : +32 65 323293, Fax. : +32 65 315691
http://www.fucam.ac.be/jourquin
--
[To unsubscribe to this list send an email to "majdart_at_bbn.com"
with the following text in the BODY of the message "unsubscribe openmap-users"]
Received on Thu Mar 03 2005 - 12:26:47 EST

This archive was generated by hypermail 2.3.0 : Tue Mar 28 2017 - 23:25:06 EDT