Okay, so I get all done with my app and then someone wants to move it onto SQL Server 2000 (Sorry Sybase).
I use PowerDesigner, re-generate the tables, create an odbc connection to the database and update the open even of the application. Basically, it seems to work!!
But in that nasty date oriented query that Namasi was helping me with, I am getting SQL STATE 37000 errors:
I was using DATE which is not supported by SQL Server.
I changed the retrieval arguments from DATE to DATETIME.
I changed the variable in the script from a DATE to DATETIME.
I even changed the editmask controls from a DATEMASK! to DATETIMEMASK!
When I go into the datawindow and manually enter the query arguments, the dw works fine. But I am still having trouble running the app.
Here is where I currently am with the code:
Any help would be greatly appreciated.
Best regards,
Paul
int inprocess_int
int onhold_int
int targeted_int
int completed_int
string inprocess
if cbx_inprocess.checked then
inprocess = "In Process"
if (inprocess="") then
inprocess_int = 0
else
inprocess_int = 1
end if
end if
string onhold
if cbx_onhold.checked then
onhold = "On Hold"
if (onhold="") then
onhold_int = 0
else
onhold_int = 1
end if
end if
string targeted
if cbx_targeted.checked then
targeted = "Targeted"
if (targeted="") then
targeted_int = 0
else
targeted_int = 1
end if
end if
string completed
if cbx_completed.checked then
completed = "Completed"
if (completed="") then
completed_int = 0
else
completed_int = 1
end if
end if
if (inprocess_int + onhold_int + targeted_int + completed_int = 0) then
messagebox("Error!","You must select at least one Status Option")
return 1
end if
datetime startdate
datetime enddate
em_start_date.GetData(star
tdate)
messagebox("GetData Results:Start Date",string(startdate))
em_end_date.GetData(enddat
e)
messagebox("GetData Results:End Date",string(enddate))
if (date(enddate) <= date(startdate)) then
messagebox("Error!","End Date cannot be equal to or less than Start Date.")
end if
dw_1.retrieve(inprocess,on
hold,targe
ted,comple
ted,startd
ate,enddat
e)
Start Free Trial