CodeCharge Studio
search Register Login  

Web Reporting

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> Archive -> GotoCode Archive

 Problem in accessing filtered record

Print topic Send  topic

Author Message
Anurag
Posted: 04/11/2002, 1:03 AM

Sir,

I Have a problem in accessing filterd records based on a condition.

I have a Login Table "LoginTable" which have the following fields :

User_id
User_name
Password
Designation
address
dept


I have another table named "Complaints" which have the following fields:

Complaint_id
Name_of_complaintee
subject
deptt
date_of_complaint
Complaint_details


I want to display records from Complaints table on the grid-form "OfiicerGrid"
when he logged into the system whrere the Complaints.Deptt=LoginTable.dept.


Thanks in advance
CodeCharge Support
Posted: 04/11/2002, 2:04 AM

Anurag,
try to join complaints.deptt field to LoginTable.dept field on Complaints Grid form.
Andrew B
Posted: 04/11/2002, 7:34 PM

That way involves writing custom sql, or using views/queries.

Another way to do it that doesn't involve custom sql :

In your logon form, when the user is authenticated (onLogin), retrieve the dept. id from the DB :

Session("DeptID") = DLookup("LoginTable", "DeptID", "Where clause")
'take a look at the other generated code to see what it does to get the right record.

Then, when you edit the properties for your grid form, add a parameter that uses 'deptt'. Make the type 'Session' and in the var. name field put 'DeptID'

That should do it.

If you have questions, post in here again.


   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Web Database

Join thousands of Web developers who build Web applications with minimal coding.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.