472,353 Members | 1,377 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,353 software developers and data experts.

ASP Page retrieve Data from Advantage Database

Hello,
I've trying since a few Days to find a Solution for the following Problem:
(complete Query below)

My Query works if I put FROM Fpolicy WHERE Customer =12345
instead of
FROM Fpolicy WHERE Customer =?
I tried it with
FROM Fpolicy WHERE (Customer =::Customer::)
No Success
FROM Fpolicy
Brings all Datasets in Fpolicy

Did anybody see some errors in the SQL Query?
Any suggestions?

I ask it in this Forum because I want to post the Number for "Customer=?" via a asp Page someting like:

http://test/test.asp?Customer=12345

Expand|Select|Wrap|Line Numbers
  1.  
  2. FPOLICY.CUSTOMER,
  3. FPOLICY.AGREEMENT,
  4. FPOLICY.CHARACTERISTIC,
  5. FPOLICY.MASTERPOLICY,
  6. FPOLICY.POLICY,FPOLICY.EFFECTIVEDATE,FPOLICY.EXPDATE,
  7. FPOLICY.POLICYCODE,
  8. FPOLICY.GROSSPREMIUM,
  9. FPOLICY.BRANCH,
  10. FPOLICY.INSCO AS COMPANY,
  11. FPOLICY.CATEGORY,FPOLICY.RENEWIT,
  12. FPOLICY.CANCELDATE,FPOLICY.TRANSACTIONCODE,
  13.  
  14. ( SELECT FAGETR.AMOUNT- Round(ISNULL(Sum(FAGESTL.AMOUNT),0),2)
  15.   FROM  FAGETR LEFT JOIN FAGESTL ON FAGETR.CODE = FAGESTL.TransactionClosed, FAGETRT
  16.   WHERE FAGETR.TRANSACTIONTYPE=FAGETRT.CODE
  17.   AND FAGETRT.IsSettled=True
  18.   AND FAGETRT.SETTLEMODULE = 'GRE'
  19.   AND FAGETR.OWNER=1
  20.   AND FAGETR.OWNERCODE=FPOLICY.TRANSACTIONCODE
  21.   GROUP BY FAGETR.AMOUNT
  22.  
  23. UNION
  24.  
  25.   SELECT  FCUSTR.AMOUNT- Round(ISNULL(Sum(FCUSSTL.AMOUNT),0),2)
  26.   FROM  FCUSTR LEFT JOIN FCUSSTL ON FCUSTR.CODE = FCUSSTL.TransactionClosed, FCUSTRT
  27.   WHERE FCUSTR.TRANSACTIONTYPE=FCUSTRT.CODE
  28.   AND FCUSTRT.IsSettled=True
  29.   AND FCUSTR.OWNERCODE=FPOLICY.TRANSACTIONCODE
  30.   AND FCUSTR.OWNER=1
  31.   GROUP BY FCUSTR.AMOUNT) AS BALANCE
  32.  
  33. FROM Fpolicy WHERE Customer =?
  34.  
  35.  
Oct 21 '06 #1
0 1508

Sign in to post your reply or Sign up for a free account.

Similar topics

10
by: Don | last post by:
I want the server-side php script to return a browser page that is essentially a copy of the original client page that contained the <form> which...
3
by: t-ball | last post by:
I am new to the world of ASP, and at the same time VBscript (also a firt time poster). I am currently creating a multiple page form where the...
4
by: Rob Meade | last post by:
Hi all, Ok - this leads on from speaking to a couple here and in the SQL server group... I've an application which allows the user to type in...
4
by: Belinda | last post by:
Hello All I need to read a SQL Server table into a Web Page and within the Web Page to permit my users to make changes to the records, delete or...
1
by: Evan Nelson | last post by:
We are running a website on 3 W2K servers running IIS 5.0 as the webservers and using a server running under Windows Server 2003 for the database...
8
by: Galina | last post by:
Hello I have 6 dependent list boxes on my ASP page:  Faculty;  Lecturer;  Course;  Course occurrence;  Group;  Week commencing date....
6
by: Rod Snyder | last post by:
I'm trying to set up an asp.net (vb.net) that will allow a user to insert/update a bio/profile. I wanted to create a SQL Server 2000 table that...
0
by: Oz | last post by:
Hi Using VS.NET 2003, Windows XP SP1, We have a page which has been developed using ASP.NET. On it, is a button which when clicked is supposed...
1
by: Jon Paal | last post by:
I have a textbox in a form that saves information to a database. A linkbutton activates a function from the user's click to save the data. A...
1
by: Kemmylinns12 | last post by:
Blockchain technology has emerged as a transformative force in the business world, offering unprecedented opportunities for innovation and...
0
by: Naresh1 | last post by:
What is WebLogic Admin Training? WebLogic Admin Training is a specialized program designed to equip individuals with the skills and knowledge...
0
jalbright99669
by: jalbright99669 | last post by:
Am having a bit of a time with URL Rewrite. I need to incorporate http to https redirect with a reverse proxy. I have the URL Rewrite rules made...
0
by: Matthew3360 | last post by:
Hi there. I have been struggling to find out how to use a variable as my location in my header redirect function. Here is my code. ...
2
by: Matthew3360 | last post by:
Hi, I have a python app that i want to be able to get variables from a php page on my webserver. My python app is on my computer. How would I make it...
0
by: AndyPSV | last post by:
HOW CAN I CREATE AN AI with an .executable file that would suck all files in the folder and on my computerHOW CAN I CREATE AN AI with an .executable...
0
by: Arjunsri | last post by:
I have a Redshift database that I need to use as an import data source. I have configured the DSN connection using the server, port, database, and...
0
Oralloy
by: Oralloy | last post by:
Hello Folks, I am trying to hook up a CPU which I designed using SystemC to I/O pins on an FPGA. My problem (spelled failure) is with the...
0
by: Rahul1995seven | last post by:
Introduction: In the realm of programming languages, Python has emerged as a powerhouse. With its simplicity, versatility, and robustness, Python...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.