dbTalk Databases Forums  

microsoft visual foxpro odbc driver problem

comp.databases.xbase.fox comp.databases.xbase.fox


Discuss microsoft visual foxpro odbc driver problem in the comp.databases.xbase.fox forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
hollyli
 
Posts: n/a

Default microsoft visual foxpro odbc driver problem - 08-06-2003 , 11:27 AM







When my .net application uses "microsoft visual foxpro odbc driver" to
execute a SQL statement as following:
select * from ordersTable where var(mycolumn) >1000
I got error:
could not find var.prg

I throught var function is supported by the driver, could someone help
me here. Thanks.
Holly Li

--
Posted via http://dbforums.com

Reply With Quote
  #2  
Old   
Dan Freeman
 
Posts: n/a

Default Re: microsoft visual foxpro odbc driver problem - 08-06-2003 , 12:37 PM






Var() is valid as a parameter to the CALCULATE command, not as a standalone
function.

Dan

"hollyli" <member35131 (AT) dbforums (DOT) com> wrote

Quote:
When my .net application uses "microsoft visual foxpro odbc driver" to
execute a SQL statement as following:
select * from ordersTable where var(mycolumn) >1000
I got error:
could not find var.prg

I throught var function is supported by the driver, could someone help
me here. Thanks.
Holly Li

--
Posted via http://dbforums.com



Reply With Quote
  #3  
Old   
hollyli
 
Posts: n/a

Default Re: microsoft visual foxpro odbc driver problem - 08-06-2003 , 02:25 PM




Thanks.
Then could you tell me how to convert a String to a number?
The situation is that there is a column in table "orders" called
"date" that stores "date" as string of seconds. I wanted to do a
"select " like:
select * from orders where date>somenumber
Since the "date" is stored as string and I don't want to compare String,
I am thinking of converting the "date" to number first. Any ideas?
Thanks a lot.
Holly Li

--
Posted via http://dbforums.com

Reply With Quote
  #4  
Old   
Dan Freeman
 
Posts: n/a

Default Re: microsoft visual foxpro odbc driver problem - 08-07-2003 , 12:58 PM



I had a hunch that's what you were looking for.

Val(String) will convert your string to a number.

or, convert your number to a string: Transform(number)

Dan

"hollyli" <member35131 (AT) dbforums (DOT) com> wrote

Quote:
Thanks.
Then could you tell me how to convert a String to a number?
The situation is that there is a column in table "orders" called
"date" that stores "date" as string of seconds. I wanted to do a
"select " like:
select * from orders where date>somenumber
Since the "date" is stored as string and I don't want to compare String,
I am thinking of converting the "date" to number first. Any ideas?
Thanks a lot.
Holly Li

--
Posted via http://dbforums.com



Reply With Quote
  #5  
Old   
Gene Wirchenko
 
Posts: n/a

Default Re: microsoft visual foxpro odbc driver problem - 08-07-2003 , 12:59 PM



hollyli <member35131 (AT) dbforums (DOT) com> wrote:

Quote:
Thanks.
Then could you tell me how to convert a String to a number?
That is val() not var().

Quote:
The situation is that there is a column in table "orders" called
"date" that stores "date" as string of seconds. I wanted to do a
"select " like:
select * from orders where date>somenumber
Since the "date" is stored as string and I don't want to compare String,
I am thinking of converting the "date" to number first. Any ideas?
Thanks a lot.
Sincerely,

Gene Wirchenko

Computerese Irregular Verb Conjugation:
I have preferences.
You have biases.
He/She has prejudices.


Reply With Quote
  #6  
Old   
hollyli
 
Posts: n/a

Default Re: microsoft visual foxpro odbc driver problem - 08-07-2003 , 01:58 PM




Thank you very very much!
Holly.

--
Posted via http://dbforums.com

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.