R2i DotNetNuke® Forum

R2i wants you to have the opportunity to ask questions, post reviews, help others or just rant and rave about DotNetNuke® or any of the R2i Modules and Skins. Our team spends hour upon hour, day after day, working on custom DotNetNuke® modules and services; please feel free to ask us anything.
 
IIF syntax error
Last Post 01 Jan 1900 05:00 AM by . 1 Replies.
Printer Friendly
Sort:
PrevPrev NextNext
You are not authorized to post a reply.
Author Messages Informative
knopflerUser is Offline
New Member
New Member
Posts:81

--
16 Jun 2006 01:06 PM  
I have installed version 1.7.4. and would like to make my compliments. The interface improvements are a welcome addition.

Maybe you already know about the following but I found a problem. I am trying to Execute a query which contains the following iif:
{IIF,"'[Account,F]'='-1'","@AccountID=NULL","@AccountID=3"}

Executing the query results in an error:
System.Data.SqlClient.SqlException: Line 21: Incorrect syntax near ','.
Unclosed quotation mark before the character string '","@AccountID=NULL","@AccountID=3"}

The "Actual" line in the query is as follows:
{IIF,"'-1"'='-1'","@AccountID=NULL","@AccountID=3"}

As you can see the quotation is incorrect. I have worked arround this problem by not using [Account,F] the problem is the ",F"
knopflerUser is Offline
New Member
New Member
Posts:81

--
16 Jun 2006 01:14 PM  
I found the source of my problem. I made a mistake in my listtemplate. this resulted in a value of -1" in stead of "-1" which caused the syntax error in my IFF.
My appologies.
You are not authorized to post a reply.

Active Forums 4.1
 

New York, NY • Baltimore, MD • Vienna, VA • St. Louis, MO • Seatle, WA • 410.327.0007 • info@R2Integrated.com

Bookmark & Share Bookmark and Share