Re: [racket-users] How to store SQL query text outside Racket source code?

2017-08-01 Thread Alex Harsanyi
On Tuesday, August 1, 2017 at 8:45:25 PM UTC+8, david.vanderson wrote: > On 07/31/2017 10:46 PM, Alex Harsanyi wrote: > > Unfortunately, `define-runtime-path` can only be used at top-level, so the > > above code does not compile. It works fine without the > > `define-runtime-path', > > I need to

Re: [racket-users] How to store SQL query text outside Racket source code?

2017-08-01 Thread David Storrs
Building on Dave Vanderson's answer: Most of my files seem to have (define-runtime-path thisdir ".") at the top. On Tue, Aug 1, 2017 at 8:45 AM, David Vanderson wrote: > On 07/31/2017 10:46 PM, Alex Harsanyi wrote: > >> Unfortunately, `define-runtime-path` can only be used at top-level, so the

Re: [racket-users] How to store SQL query text outside Racket source code?

2017-08-01 Thread David Vanderson
On 07/31/2017 10:46 PM, Alex Harsanyi wrote: Unfortunately, `define-runtime-path` can only be used at top-level, so the above code does not compile. It works fine without the `define-runtime-path', I need to use it so they query files are found when the application is compiled to a stand-alone e

Re: [racket-users] How to store SQL query text outside Racket source code?

2017-07-31 Thread Alex Harsanyi
On Tuesday, August 1, 2017 at 12:11:24 PM UTC+8, gneuner2 wrote: > Hmm.  A change to a query often also means a change to its arguments > and/or its result columns, so I don't see that there is much utility > in keeping the query strings separate from the program.  I'm not trying

Re: [racket-users] How to store SQL query text outside Racket source code?

2017-07-31 Thread George Neuner
On 7/31/2017 10:46 PM, Alex Harsanyi wrote: I'm trying to write a function to keep the SQL query text outside of the Racket source code, as this would make it easier to write and test the SQL code. Instead of writing: (define query (virtual-statement (lambda (dbsys) "select ..."))) I wo

[racket-users] How to store SQL query text outside Racket source code?

2017-07-31 Thread Alex Harsanyi
I'm trying to write a function to keep the SQL query text outside of the Racket source code, as this would make it easier to write and test the SQL code. Instead of writing: (define query (virtual-statement (lambda (dbsys) "select ..."))) I would like to put the "select ..." part in a separ