Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SQL passthru with a variable in a variable
Message
De
09/03/2003 11:47:48
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
SQL passthru with a variable in a variable
Divers
Thread ID:
00763438
Message ID:
00763438
Vues:
47
I am trying to create a date variable will go into my z variable but do not know the proper way to format it when I am making z. Below is the code:

lv_date=TTOC(DATE() - 90)

STORE SQLCONNECT('VFPOracle', 'large_oracle', 'larg') TO gnconnhandle
******************************** GS 1
a= "select * "
b= " from larger_survey "
c= " where queue_department = 'General Support'"
d= " and response_date >= '" &&trunc(sysdate)-30
e= "' -30 and response_date < " &&trunc(sysdate)
f= " and metric_name = 'Overall'"
g= " and metric_score = 5"
z= a+b+c+d+ lv_date +e+ lv_date +f+g

= SQLSETPROP(gnconnhandle, 'asynchronous', .f.)
= SQLEXEC(gnconnhandle, z, 'mycursor')
SELECT mycursor


I have tried using lv_date as just date() or as a text date but can not make it work. What am I doing wrong???
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform