Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / General MS InfoPath Questions / July 2007

Tip: Looking for answers? Try searching our database.

Queryfields vanishing

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Clothahump - 27 Jul 2007 15:53 GMT
I'm a noob at this and the answer will probably be very simple.

I've inherited an application that runs on a SQL Server.  We need to
move it to another SQL Server.  There are numerous views (it's a
survey form) and many tables are referenced.   The opening form has
two text boxes for ID and Password that are bound to two fields
defined as queryFields.  When the user logs in, it retrieves his
master record and all the surveys associated with it.

My thought was to do as follows:

1.  In design mode, click Tools/Data Connection/Main connection/
Modify.
2.  Click Edit Sql, then copy the SQL code and save it in a text file.
3.  Click Change Database, then select the new database that I want to
point at.
4.  Click Edit Sql, then paste the SQL code from the text file and
save it.

When I do this, I see only dataFields.  I lose the queryFields.  How
can I regain them?

Thanks in advance!
Kalyan G Reddy MVP (GGK Tech) - 27 Jul 2007 17:36 GMT
Hello

When you copied the New SQl Code make sure that you have the Input
parameters in the code.
Signature

Kalyan G Reddy - INFOPATH MVP 2007
http://www.ggktech.com

> I'm a noob at this and the answer will probably be very simple.
>
[quoted text clipped - 19 lines]
>
> Thanks in advance!
Clothahump - 27 Jul 2007 18:04 GMT
On Jul 27, 11:36 am, Kalyan G Reddy MVP (GGK Tech)
<KalyanGReddyMVPGGKT...@discussions.microsoft.com> wrote:
> Hello
>
> When you copied the New SQl Code make sure that you have the Input
> parameters in the code.
> --
---------------

???

I'm confused - there weren't any input parameters in the code that I
copied.

Here's a sample of it (I chopped out the vast majority of the joins):

shape
    {select
"PatientID","PatientName","Password","AgeGroup","DOB","Gender","MaritalStatus","Race","RaceOther","Ethnicity","Occupation","OccupationOther","Onset","PreDx","FamHx1","FamHx2","PreTrx","PostTrx","YearlyIncome","Charity","CurrentEpisode","CurrentTimepoint","CurrentTimepointDate","CountryOfResidence","CountryOther","StateOfResidence","EducationLevel","WorkStatus","SchoolStatus","EnglishPrimaryLang","OtherPrimaryLang","OtherSpokenLang","HouseholdIncome","PersonalIncome","InsuranceStatus","InsuranceStatusOther","FamilyMembersFormalDx","FamilyMembersFormalDxRelation","FamilyMembersInformalDx","FamilyMembersInformalDxRelation","OutputClinician","HowManyChildren"
from "dbo"."PatientMaster" as "PatientMaster"} as "PatientMaster"
        ({select
"PatientID","Episode","Timepoint","TimepointDate","TimepointDesc","Complete","AAQR1","AAQR2","AAQR3","AAQR4","AAQR5","AAQR6","AAQR7","AAQR8","AAQR9","AAQR10","AAQR11","AAQR12","AAQR13","AAQR14","AAQR15","AAQR16","AAQR17","AAQR18","AAQR19"
from "dbo"."PatientAAQR" as "PatientAAQR"}
            relate "PatientID" TO "PatientID","CurrentEpisode" TO
"Episode","CurrentTimepoint" TO "Timepoint","CurrentTimepointDate" TO
"TimepointDate") as "PatientAAQR",
        ({select
"PatientID","Episode","Timepoint","TimepointDate","TimepointDesc","Complete","ASI1","ASI2","ASI3","ASI4","ASI5","ASI6","ASI7","ASI8","ASI9","ASI10","ASI11","ASI12","ASI13","ASI14","ASI15","ASI16"
from "dbo"."PatientASI" as "PatientASI"}
            relate "PatientID" TO "PatientID","CurrentEpisode" TO
"Episode","CurrentTimepoint" TO "Timepoint","CurrentTimepointDate" TO
"TimepointDate") as "PatientASI"

etc.

Where would I add input parameters?
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.