• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Help With Simple CFIF question please

New Here ,
Apr 24, 2012 Apr 24, 2012

Copy link to clipboard

Copied

    I am trying to check the contents of 2 form elements against existing database enties and then if either of them are differnet run a conditional option but I am having some issues as the below does not seem to be working. Am I doing something wrong?

<cfquery name="qLiveService" datasource="#application.datasource#">

        SELECT broadcastPackage, AdditonalDVDs

        FROM dbo.tributes

        WHERE profileID = 122>

    </cfquery>  

    

       

<cfif qLiveService.broadcastPackage is form.broadcastPackage and qLiveService.AdditonalDVDs is form.AdditonalDVDs >

<!--- do something -->

<cfelse>

<!--- of one was different now run the code in this area -->

</cfif>

Views

606

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Apr 24, 2012 Apr 24, 2012

Copy link to clipboard

Copied

The term "does not seem to be working" is vague.  What do expect to happen and what is actually happening?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 25, 2012 Apr 25, 2012

Copy link to clipboard

Copied

LATEST

Your code seems to be all right. Just remove the symbol > from your SQL statement

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation