🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.vdbase.data.sql
Article #584

Any ideas how to make this work?

#584
From: mike
Date: Tue, 20 Oct 1998 00:00
23 lines
1274 bytes
I am trying to use variables to create a query statement:

the dbmaint.dbf database has the following fields +.
unti_num = numeric 8,0
entrydate = date 8,0

unit is loaded from a form entry field that formats it as text. 
I then use the VAL() function to convert it to numeric.
the following statement works great.
results.query1.sql = "select * from dbmaint.dbf where unit_num = " +unit

sdate is loaded the same way as unit, from an entry field on a form that
is formated at a date entry field.
the following statement does NOT work.
results.query1.sql = "select * from dbmaint.dbf where unit_num = " +unit
+ " and entrydate >=" +sdate 
 
Can this be made to work?
Is this the way I should be trying to do this?  

All help will be greatly appreciated!

Mike Kirkland
Technical Details
Message-ID: <362CB185.25FCA8EF@notgiven.com>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: ff5a1,a104ec5b907376c2,start
X-Google-Attributes: gidff5a1,public
From: mike <none@notgiven.com>
Subject: Any ideas how to make this work?
Date: 1998/10/20
Message-ID: <362CB185.25FCA8EF@notgiven.com>
X-Deja-AN: 403214806
Content-Transfer-Encoding: 7bit
Organization: Another Netscape Collabra Server User
Content-Type: text/plain; charset=us-ascii
Mime-Version: 1.0
Newsgroups: borland.public.vdbase.data.sql