Hi,
You may want to create a user defined function that returns a ResultSet,
and where you can pass a custom SQL statement, in addition to the jdbc URL
/ user name / password of MS SQL Server. This function can then be used
just like a table:
insert into ... select * from query('jdbc:...', '..', '..', 'select top 100
from ...');
Regards,
Thomas
On Sat, Apr 13, 2013 at 12:49 PM, Noel Grandin <[email protected]>wrote:
> It is possible to do something like
>
> CREATE LINKED TABLE LINK('', 'jdbc:h2:test2', 'sa', 'sa',
> '(SELECT TOP 200 * FROM TEST)');
>
> But you wouldn't be able to pass in parameters.
>
> This is actually a case where something like a DATABASE LINK would be
> more useful, since it would allow you to pass custom SQL.
>
> --
> You received this message because you are subscribed to the Google Groups
> "H2 Database" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at http://groups.google.com/group/h2-database?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>
--
You received this message because you are subscribed to the Google Groups "H2
Database" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/h2-database?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.