Log inUsernamePassword
Log me on automatically each visit    
Register
Register
Log in to check your private messages
Log in to check your private messages
Visual Basic Forum for Visual Basic Programmers VB Forum Index » Database & Reporting

Post new topic   Reply to topic
Help, Help, Help !!!!!!!!
View previous topic :: View next topic  
Author Message
makspetar
Newbie


Joined: 17 Feb 2005
Posts: 1

PostPosted: Feb 17th, 2005 07:36 AM    Post subject: Help, Help, Help !!!!!!!! Reply with quote

Please, help me !!!!!!!!!!!!!! Cry

I want to make application which have 3 tables (COUNTRY, CITY, FACTORY). Tables is created on Oracle database. Forms for input data is created on VB(6.0). I want to create report(Data Report) which show data from this table, but I want to choose country, city or factory. When country is choose, then report show that country, same is for city and factory. Because that I think to use parameter list. I know to created report which show date from all tables and report which show data with parameter query, but it is not enough. I want to amplify existent Command ( DataEnvironment.Command2-Command3-Command4 interrelation as parent and child) which show all data from tables.

Code:

Dim strS As String

Private Sub cmdRunReport_Click()
If DataEnvironment1.rsCommand2.State = adStateOpen Then
DataEnvironment1.rsCommand2.Close
End If
If txtCountry.Text = "" Then
DataEnvironment1.Command2
rptProba.Show
Else
strS = "SHAPE {SELECT code, name FROM country"
strS = strS & " where name = ?}"
strS = strS & " AS Command2 "
strS = strS & "APPEND (( SHAPE {SELECT code_country, code_city, name FROM city}"
strS = strS & "AS Command3 "
strS = strS & "APPEND ({SELECT code_c, name, telefon FROM PR.factory}"
strS = strS & "AS Command4 RELATE 'code_city' TO 'code_c') AS Command4)"
strS = strS & "AS Command3 RELATE 'code' TO 'code_country') AS Command3"

DataEnvironment1.Commands!Command2.CommandText = strS
DataEnvironment1.Commands!Command2(0) = txtCountry.Text
DataEnvironment1.Command2
rptProba.Show
End If
End Sub
How I to add parameter for city and factory, and how I to execute then Command?????????????? Cry
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Visual Basic Forum for Visual Basic Programmers VB Forum Index » Database & Reporting All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Visual Basic Forum runs phpBB | Forum Template © iOptional
VB Resources | SSL | Visual Basic