Syntax Error in the Query

Dear All,
Please tell me syntax error in the below query. When I'm going to write numeric number in this filed "$[ OVPM.DocNUm ]". It's working fine. But when I'm writing this it give me error.Please clear me where am wrong????I
SELECT T0.[AcctNum] FROM VPM1 T0 WHERE T0.[DocNum] =$ [OVPM.DocNUm ]
Regards
Edited by: Anwar Ali Sohail on Sep 27, 2011 11:43 AM

HI
Try This
SELECT T0.[CheckNum] FROM VPM1 T0  INNER JOIN OVPM T1 ON T0.DocNum = T1.DocEntry WHERE T0.[DocNum] = $[OVPM.DocNum]
OR
SELECT T0.[AcctNum] FROM VPM1 T0  INNER JOIN OVPM T1 ON T0.DocNum = T1.DocEntry WHERE T0.[DocNum] = $[OVPM.DocNum]
Edited by: kambadasan on Sep 27, 2011 4:26 PM

Similar Messages

  • [Execute SQL Task] Error: Executing the query "DECLARE_@XMLA nvarchar(3000) ,__@DateSerial nvarch..." failed with the following error: "Incorrect syntax near '-'.". Possible failure reasons: Problems with the query, "ResultSet" property not set correctly,

    Hi
    DECLARE @XMLA nvarchar(3000)
    , @DateSerial nvarchar(35);
    -- Change date to format YYYYMMDDHHMMSS
    SET @DateSerial = CAST(GETDATE() AS DATE);
    --SELECT @DateSerial
    Set @XMLA = 
    N' <Batch xmlns="http://schemas.microsoft.com/analysis services/2003/engine">
     <ErrorConfiguration xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ddl2="http://schemas.microsoft.com/analysisservices/2003/engine/2"
    xmlns:ddl2_2="http://schemas.microsoft.com/analysisservices/2003/engine/2/2" xmlns:ddl100_100="http://schemas.microsoft.com/analysisservices/2008/engine/100/100" xmlns:ddl200="http://schemas.microsoft.com/analysisservices/2010/engine/200"
    xmlns:ddl200_200="http://schemas.microsoft.com/analysisservices/2010/engine/200/200">
    <KeyErrorLimit>-1</KeyErrorLimit>
    <KeyNotFound>IgnoreError</KeyNotFound>
    <NullKeyNotAllowed>IgnoreError</NullKeyNotAllowed>
     </ErrorConfiguration>
     <Parallel>
    <Process xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ddl2="http://schemas.microsoft.com/analysisservices/2003/engine/2" xmlns:ddl2_2="http://schemas.microsoft.com/analysisservices/2003/engine/2/2"
    xmlns:ddl100_100="http://schemas.microsoft.com/analysisservices/2008/engine/100/100" xmlns:ddl200="http://schemas.microsoft.com/analysisservices/2010/engine/200" xmlns:ddl200_200="http://schemas.microsoft.com/analysisservices/2010/engine/200/200"
    xmlns:ddl300="http://schemas.microsoft.com/analysisservices/2011/engine/300" xmlns:ddl300_300="http://schemas.microsoft.com/analysisservices/2011/engine/300/300">
     <Object>
     <DatabaseID>MultidimensionalProject5</DatabaseID>
     <CubeID>giri</CubeID>
     <MeasureGroupID>Fact Internet Sales</MeasureGroupID>
     </Object>
     <Type>ProcessFull</Type>
     <WriteBackTableCreation>UseExisting</WriteBackTableCreation>
     </Process>
      </Parallel>
    </Batch>';
    EXEC (@XMLA) At SHALL-PCAdventureWorksDw ;
     iam executive the    query when iam getting below error.
      [Execute SQL Task] Error: Executing the query "DECLARE
    @XMLA nvarchar(3000)
    , @DateSerial nvarch..." failed with the following error: "Incorrect syntax near '-'.". Possible failure reasons: Problems with the query, "ResultSet" property not set correctly, parameters not set
    correctly, or connection not established correctly. 
     how to solve this error;
     please help me

    What are you trying to do? What sort of data source is  SHALL-PCAdventureWorksDw?
    When you use EXEC() AT, I would execpt to see an SQL string to be passed to EXEC(), but you are passing an XML string????
    If you explain why you think this would work in the first place, maybe we can help you.
    Erland Sommarskog, SQL Server MVP, [email protected]

  • "Syntax error in the MDX statement " in Process chain failure??Urgent pls

    Hi Experts,
    could any one suggest me the procedure to rectify the below problems in process chain?
    1."Syntax error in the MDX statement "
    2."Error when getting data (Error when getting data (AXI))"
    Rgds,
    BH

    In which case it'll be that Access has a different date format to MySQL, and you're trying to push the string "'25-Apr-12 10:55 PM" into Access, which it's not understanding. To get around this, you need to treat your variable as a true date/time object, rather than a formatted string.
    CFQueryParams should be used on absolutely every database platform, they'll stop your website being vulnerable to SQL Injection attacks for one, which at the moment you're wide open to. Replace your query with something like this:
    <cfquery name="input_comments" datasource="#DSN#" username="#DSNUSER#" password="#DSNPASS#">
          INSERT INTO comments(
                             commenter,
                             comment,
                             datetime,
                             post_id
                   VALUES(
                             <cfqueryparam cfsqltype="cf_sql_varchar" value="#form.commenter#" />,
                             <cfqueryparam cfsqltype="cf_sql_varchar" value="#form.comment#" />,
                             now(),
                             <cfqueryparam cfsqltype="cf_sql_numeric" value="#form.post_id#" /> )
    </cfquery>
    The QueryParams will handle the data types for you, and should pass values around more safely and with fewer issues. Assuming you just want to store the current date and time you don't even need to get ColdFusion involved, as databases have their own functions for this. I believe Access' version is simply NOW(), so I've put that in your query.
    Give the above a go.

  • Syntax error in ABAP query after implement patch

    Dear All,
    After implement patch from SAPKA46C39 to SAPKA46C53, we have syntax error in our query.
    our SAP release version is 46C.
    The error in query is -The data object "R01" does not have a component called "046" -
    We don't found any SAP notes that match for our error.
    Anyone ..please help...
    Thanks a lot...
    Budituta

    Hi,
    The query generated is based on the table structures available as they are used, etc.
    So please check if there is any difference in the fields available in the tables used, LDB used if any.
    In addition, may be few of the properties of the SAP query and info set does not get copied properly.
    and after activating the info set only, activate the query, etc...check them once again.
    Regards,
    Santhosh.

  • [Execute SQL Task] Error: Executing the query failed with error: "The COMMIT TRANSACTION request has no corresponding BEGIN TRANSACTION."

    I have an package with source , data flow and destination to execute on begin and commit.
    in the below i have just used for questioning purpose with diagram removing my Data Flow task explaining my problem
    on execution, i get error as
    [Execute SQL Task] Error: Executing the query "COMMIT TRAN DimCompanyCode" failed with the following error: "The COMMIT TRANSACTION request has no corresponding BEGIN TRANSACTION.". Possible failure reasons: Problems with the query, "ResultSet"
    property not set correctly, parameters not set correctly, or connection not established correctly.
    as mentioned , i have checked the ResultSet, parameters , connection establish.. all are fine.
    Kindly advice on what has to be done.
    ShanmugaRaj

    To avoid this error, the RetainSameConnection property should set to 'True' for the Connection Manager - Application_DB.
    Narsimha

  • Syntax error in the program SAPLSYMB

    Hi
    I have installed ECC6 on windows 2003 server  sqlserver 2005 as database. We are getting error at the time applying basis patch. The patch process is stopped at import_proper stage.
    When i try to execute any transaction , the error is "syntax error in the program SAPLSYMB". I have cleard the transaction log, still  the errro is same.
    When I try to relogin the error is same, I am unable to execute any transaction.
    Please do the needful
    Regards
    Prasanna.B.S

    Hellow,
    I have the same error, and I executed this command for 12 hours
    tp r3i SAPKB70017 ITP pf=/usr/sap/trans/bin/TP_DOMAIN_ITP.PFL tag=spam -Dclientcascade=yes -Drepeatonerror=8
    the message in cmd is
    earth\sapmnt\trans\tmp\SLOG0914.ITP.LOC is already in use (14474), I'm waiting
    2 sec (20090401065221). My name: pid 4188 on earth (dministrator)
    But this file (SLOG0914.ITP.LOC ) is in 0 kb, is this normally ?
    Please Help me
    Regards
    Graciela

  • Syntax error near the ['on']

    Can anyone please advise on how to resolve this issue, I created Dim load file but whenever I try loading the Dim it returns - syntax error near the ['on']
    thanks

    I don't see the issue
    Delimiter was set as comma, first line was ignored and it all loaded fine.
    Cheers
    John

  • Error executing the Query after deploying and executing the application in WLS 6.1 SP3

    Hi,
    We are trying to run a application by deploying a war file on Web Logic Server
    6.1 SP3. After deploying and at the time of execution of the application, the
    server console displays this error message
    java.sql.SQLException: ORA-00600: internal error code, arguments: [ttcgcshnd-1],
    [0], [], [], [], [], [], []
    While debugging thru the application we found that this error comes at the time
    of execution of the query thru the Statement.executeQuery method of java.sql.Statement
    class.
    This same application when deployed on Web Logic Server 8.1 runs perfectly, without
    any hitches.
    Please, provide me the solution to this asap.

    Look for sometime around November. No exact date.
    Eric
    "Dominic Tulley" <[email protected]> wrote in message
    news:[email protected]..
    Thanks Eric,
    you know what I'm going to ask next right?
    Any ideas when SP4 comes out?
    Cheers,
    -Dominic
    "Eric Gross" <[email protected]> wrote in message
    news:[email protected]..
    The next version of Apache that we will support will be 2.0.42/2.0.43
    and
    the module for that will be included in the next Service Pack for6.1(SP4)
    and 7.0(SP2).
    The problem with Apache 2 is that when a new release comes out a newmodule
    needs to be compiled. Most of the time. For 2.0.42/2.0.43 this is notthe
    case.
    Regards,
    Eric
    "Dominic Tulley" <[email protected]> wrote in
    message
    news:3da3f246$[email protected]..
    I'm trying to set this up (initially just apache in front of a single
    WLS
    server but ultimately I want to put it in front of a cluster).
    I've installed Apache 2.0.40.
    I've copied the mod_wl_20.so file into the apache modules folder.
    I've edited the httpd.conf file and added the line:
    LoadModule weblogic_module modules/mod_wl_20.so
    When I run apache -t to check the configuration I get the following:
    C:\Program Files\Apache Group\Apache2\bin>apache -t
    Syntax error on line 173 of C:/Program Files/Apache
    Group/Apache2/conf/httpd.conf:
    Cannot load C:/Program Files/Apache Group/Apache2/modules/mod_wl_20.sointo
    server: The specified procedure could not be found.
    So what's going on here?
    Looking at previous postings it sounds like there's an issue with
    versions
    of apache after 2.0.39 but I can't find a download for that version.Also,
    it sounded like the issues were for WLS 7, not 6.1. Can this work
    with
    2.0.40 or am I wasting my time?
    If I get the mod_wl_20.so from dev2dev I get the "incompatible plugin"
    message that has been mentioned in this group already.
    Any suggestions appreciated,
    -Dominic

  • MS SQL - Syntax error for valid query

    I have a problem with the second query in this code (gives me
    a syntax error in my HAVING line)
    <cfquery name="getDupes" datasource="#application.ODBC1#"
    dbtype="ODBC" username="#application.userNameODBC1#"
    password="#application.userPassODBC1#">
    SELECT *
    FROM view_FormCount
    WHERE formCount >= 2
    ORDER BY formNum
    </cfquery>
    <cfset variables.lstForms = "">
    <cfoutput query="getDupes">
    <cfset variables.lstForms=
    listAppend(variables.lstForms,"'#getDupes.formNum#'")>
    </cfoutput>
    <cfset variables.whereClause = "(formNum =
    #ReplaceNoCase(variables.lstForms,',',' OR formNum =
    ','ALL')#)">
    <cfquery name="getDetails"
    datasource="#application.ODBC1#" dbtype="ODBC"
    username="#application.userNameODBC1#"
    password="#application.userPassODBC1#">
    SELECT tblForms.formNum, tblForms.formName,
    tblForms.formCustNum, tblCompanies.companyAbbr
    FROM tblForms INNER JOIN tblCompanies ON tblForms.formCustNum
    = tblCompanies.companyNum
    GROUP BY tblForms.formNum, tblForms.formName,
    tblForms.formCustNum, tblCompanies.companyAbbr
    HAVING #variables.whereClause#
    ORDER BY tblForms.formNum, tblForms.formCustNum
    </cfquery>
    Now, the really odd thing is if I just take the query text
    out of the CFQUERY tags and use CFOUTPUT instead (to see in my
    browser what query is getting executed) I get a query that I can
    paste into Enterprise Mgr and runs fine.
    I can even paste the resulting text into my code in a CFQUERY
    and CF will run it fine.
    In other words, the dynamic version query gives me an error,
    but if I just output the SQL statement, copy-and-paste that into
    the CFQUERY that's erroring out (replacing what's there) to run as
    a static query, it works fine (sample of static query below).
    The error I get when I try to do it dynamically is "Error
    Executing Database Query. [Macromedia][SQLServer JDBC
    Driver][SQLServer]Line 4: Incorrect syntax near '10169318'. The
    error occurred on line 21." which is where the HAVING clause
    starts.
    SELECT tblForms.formNum, tblForms.formName,
    tblForms.formCustNum, tblCompanies.companyAbbr FROM tblForms INNER
    JOIN tblCompanies ON tblForms.formCustNum = tblCompanies.companyNum
    GROUP BY tblForms.formNum, tblForms.formName, tblForms.formCustNum,
    tblCompanies.companyAbbr HAVING (formNum = '10169318' OR formNum =
    '1016CONCERTA' OR formNum = '1016NSAIDS' OR formNum =
    '1016STRATTERA' OR formNum = '1016WELLBUTRIN' OR formNum =
    '18504211' OR formNum = '185093807' OR formNum = '73208565' OR
    formNum = '732120027' OR formNum = '7322154' OR formNum = '7323402'
    OR formNum = '7323522' OR formNum = '73238900' OR formNum =
    '7324211' OR formNum = '7324211S' OR formNum = '7324265' OR formNum
    = '73242891' OR formNum = '732434341' OR formNum = '732434342' OR
    formNum = '73243435' OR formNum = '73243436' OR formNum =
    '73243439' OR formNum = '73243440' OR formNum = '73243441' OR
    formNum = '73243442' OR formNum = '73243443' OR formNum = '7324359'
    OR formNum = '7324360' OR formNum = '7324370' OR formNum =
    '7324560' OR formNum = '7324959' OR formNum = '7326411ptreg' OR
    formNum = '7326599' OR formNum = '7326600' OR formNum = '7326620'
    OR formNum = '7326707' OR formNum = '7326931' OR formNum =
    '7328410' OR formNum = '732851031TOP' OR formNum = '7328512' OR
    formNum = '7328548' OR formNum = '7328548P2' OR formNum =
    '7328548P3' OR formNum = '7328548P4' OR formNum = '73289400' OR
    formNum = '73290D' OR formNum = '7329154' OR formNum =
    '73291544JHS' OR formNum = '73291545JHS' OR formNum =
    '73291546JHSMH' OR formNum = '73291547JHSMH' OR formNum = '7329174'
    OR formNum = '7329308' OR formNum = '7329402' OR formNum =
    '7329424' OR formNum = '7329455' OR formNum = '7329520' OR formNum
    = '7329539' OR formNum = '73297701JH' OR formNum = '73298273' OR
    formNum = '73298400' OR formNum = '73298403' OR formNum =
    '73298404' OR formNum = '7329883' OR formNum = '73298860' OR
    formNum = '7329887' OR formNum = '73298974' OR formNum = '7329899'
    OR formNum = '7329899S' OR formNum = '73299190' OR formNum =
    '7329987' OR formNum = '7329999PTO' OR formNum = '732AV5160' OR
    formNum = '732CMHFRAZ' OR formNum = '732HIPAA' OR formNum =
    '732HIPAAFLYERS' OR formNum = '734HEART' OR formNum = '7444711' OR
    formNum = '7449230' OR formNum = '744HR4991' OR formNum =
    '7538014MI' OR formNum = '77511044' OR formNum = '77511045' OR
    formNum = '775stampnochange' OR formNum = '80851001BLUE' OR formNum
    = '80MR4200' OR formNum = '80MR4273' OR formNum = '80MR4274' OR
    formNum = '80MR4300' OR formNum = '80MR9934' OR formNum =
    '80MR9935' OR formNum = '80SHC100' OR formNum = '80SHC4301' OR
    formNum = '80SHC9830' OR formNum = '80SHC9832') ORDER BY
    tblForms.formNum, tblForms.formCustNum

    AWFrueh1808 wrote:
    > OK, that's simple enough. But then I'm really confused
    as to why the query in
    > my original post/example didn't work.
    >
    > The only single quotes in my #whereClause# variable were
    wrapped around each
    > varchar value in the WHERE clause (well, HAVING) as in
    HAVING formNum = '12345'
    > OR formNum = '54321'
    >
    > I never used a single quote within the value itself. And
    yet
    > preservesinglequotes fixed it. So what was CF doing? Why
    did the single
    > quotes still show up in the error msg - and in the right
    place?
    >
    As I said the default behavior is to escape the quotes in
    your variables
    as data. So the default output of your SQL statement, before
    preserveSingleQuotes() would be like this.
    HAVING formNum = ''12345'' OR formNum = ''54321''
    As you can see that is not the desired results in your case.
    In your
    case you have the proper number of single quotes in your
    string and you
    do not want any added. You want to preserve them so to say.
    Thus
    adding preserveSingleQuotes() around your whereClase
    variable, i.e.
    preserveSingleQuotes(whereClause) says do not add any quotes,
    keep them
    all single.

  • Syntax error in ABAP Query

    Hi All,
    We are facing syntax erro with ABAP query.
    We have a infoset/query which is perfectly working in one system and we downloaded the both infoset and query from this system.But the same query when it is uploaded to other system is not working.
    Infoset is not giving any syntax error while activation. Morever, the generated report struture is also different from the other system. In old system, report was having one include for declaration and other for data retrieval process etc.
    Can you please help us to resolve this issue?
    Thanks

    Hi,
    The query generated is based on the table structures available as they are used, etc.
    So please check if there is any difference in the fields available in the tables used, LDB used if any.
    In addition, may be few of the properties of the SAP query and info set does not get copied properly.
    and after activating the info set only, activate the query, etc...check them once again.
    Regards,
    Santhosh.

  • Syntax error in insert query

    I have a flash form that is used to inserts a record into an
    Access database table. In the for there are 4 datefields, several
    text input fields, and several select fields. When I submit the
    form, I get a syntax error that reads:
    Executing Database Query. [Macromedia][SequeLink JDBC
    Driver][ODBC Socket][Microsoft][ODBC Microsoft Access Driver]
    Syntax error in INSERT INTO statement.
    The error occurred on line 184. Complex object types cannot
    be converted to simple values.
    Line 184 is the last line of the Values in the insert query.
    The query looks like this:
    <CFQUERY DATASOURCE="#REQUEST.DataSource#">
    INSERT INTO EstimateNumber(
    BidNumber,
    Project,
    JobSite,
    EstimatedBy,
    Region,
    Company,
    Division,
    InquiryNumber,
    SafetyChecklist,
    SafetyChecklistDate,
    QCChecklist,
    QCChecklistDate,
    EstimatedValue,
    UserUsername,
    UserPassword,
    Updated,
    ReviewDate,
    ReviewedBy,
    Discipline,
    BidDate,
    JobNumber,
    UpdatedBy
    VALUES(
    #FORM.BidNumber#,
    '#FORM.Project#',
    '#FORM.JobSite#',
    '#FORM.EstimatedBy#',
    #FORM.Region#,
    #FORM.Company#,
    #FORM.Division#,
    '#FORM.InquiryNumber#',
    #FORM.SafetyChecklist#,
    #FORM.SafetyChecklistDate#,
    #FORM.QCChecklist#,
    '#FORM.QCChecklistDate#',
    #FORM.EstimatedValue#,
    '#FORM.UserUsername#',
    '#FORM.UserPassword#',
    #FORM.Updated#,
    #FORM.ReviewDate#,
    #FORM.ReviewedBy#,
    #FORM.Discipline#,
    #FORM.BidDate#,
    #FORM.JobNumber#,
    '#FORM.UpdatedBy#'
    </CFQUERY>
    Any recomendations?

    Date/Time in Access provide some pretty strage hurdles. In
    many occassions I have simply changed the field to a Text field and
    ran with that and never seemed to have problems with the result. I
    didn't like doing it but I never received errors. I have been
    receiving some parameter errors with <cfqueryparam> like the
    database doesn't recognized the preceding declared field in the
    update or insert query. Here is an example of a wierd error with
    Access. I have 2 tables. One is for estimate numbers and the other
    is for sub estimate numbers that can be assigned to specific
    estimate numbers. If is actually a complicated explanation about
    what is taking place behind the doors on this. The concept is
    simple on the surface. Both tables have the same fields except the
    subestimate table has 1 extra for a user defined subestimate
    number. The only relation between the two will be the estimate
    number. This insert works fine.
    INSERT INTO EstimateNumber(
    BidNumber,
    Project,
    JobSite,
    EstimatedBy,
    Region,
    Company,
    Division,
    InquiryNumber,
    SafetyChecklist,
    SafetyChecklistDate,
    QCChecklist,
    QCChecklistDate,
    EstimatedValue,
    UserUsername,
    UserPassword,
    ReviewDate,
    Discipline,
    BidDate,
    JobNumber,
    UpdatedBy
    VALUES(
    #FORM.BidNumber#,
    '#FORM.Project#',
    '#FORM.JobSite#',
    '#FORM.EstimatedBy#',
    #FORM.Region#,
    #FORM.Company#,
    #FORM.Division#,
    '#FORM.InquiryNumber#',
    #FORM.SafetyChecklist#,
    <cfqueryparam
    value="#FORM.SafetyChecklistDate#"
    cfsqltype="CF_SQL_DATE "
    maxlength="50"
    >,
    #FORM.QCChecklist#,
    <cfqueryparam
    value="#FORM.QCChecklistDate#"
    cfsqltype="CF_SQL_DATE "
    maxlength="50"
    >,
    #FORM.EstimatedValue#,
    '#FORM.UserUsername#',
    '#FORM.UserPassword#',
    <cfqueryparam
    value="#FORM.ReviewDate#"
    cfsqltype="CF_SQL_DATE "
    maxlength="50"
    >,
    #FORM.Discipline#,
    <cfqueryparam
    value="#FORM.BidDate#"
    cfsqltype="CF_SQL_DATE "
    maxlength="50"
    >,
    #FORM.JobNumber#,
    '#FORM.UpdatedBy#'
    This next one is the same exact query with the same table
    setup with one added field but kicks back a parmeter error
    expecting 4. I can't explain it.
    INSERT INTO SubEstimate(SubBidNumber,
    BidNumber,
    Project,
    JobSite,
    EstimatedBy,
    Region,
    Company,
    Division,
    InquiryNumber,
    SafetyChecklist,
    SafetyChecklistDate,
    QCChecklist,
    QCChecklistDate,
    EstimatedValue,
    UserUsername,
    UserPassword,
    ReviewDate,
    Discipline,
    BidDate,
    JobNumber,
    UpdatedBy
    VALUES(#FORM.SubBidNumber#,
    #FORM.BidNumber#,
    '#FORM.Project#',
    '#FORM.JobSite#',
    '#FORM.EstimatedBy#',
    #FORM.Region#,
    #FORM.Company#,
    #FORM.Division#,
    '#FORM.InquiryNumber#',
    #FORM.SafetyChecklist#,
    <cfqueryparam
    value="#FORM.SafetyChecklistDate#"
    cfsqltype="CF_SQL_DATE "
    maxlength="50"
    >,
    #FORM.QCChecklist#,
    <cfqueryparam
    value="#FORM.QCChecklistDate#"
    cfsqltype="CF_SQL_DATE "
    maxlength="50"
    >,
    #FORM.EstimatedValue#,
    '#FORM.UserUsername#',
    '#FORM.UserPassword#',
    <cfqueryparam
    value="#FORM.ReviewDate#"
    cfsqltype="CF_SQL_DATE "
    maxlength="50"
    >,
    #FORM.Discipline#,
    <cfqueryparam
    value="#FORM.BidDate#"
    cfsqltype="CF_SQL_DATE "
    maxlength="50"
    >,
    #FORM.JobNumber#,
    '#FORM.UpdatedBy#'
    IF I get rid of the cfqueryparam fields it works. If I simply
    remove the param, I get a Syntax error. Needless to say I commented
    this query for the sake of sanity for the time being.

  • Syntax errors in update query with inner joins and sub query.

    Below is the query:
    UPDATE sp_CFQ_Coord_Corrections 
    INNER JOIN (CFQ_Coord_Corrections 
    INNER JOIN CFQ_Referrals ON CFQ_Coord_Corrections.CorrID = CFQ_Referrals.RecID) 
    ON sp_CFQ_Coord_Corrections.ID = CFQ_Referrals.RecID 
    SET CFQ_Coord_Corrections.MatchFound = 1, 
    CFQ_Coord_Corrections.RecTblID = [CFQ_Referrals].[RecTblID], 
    sp_CFQ_Coord_Corrections.MatchFound = 1
    WHERE (((CFQ_Coord_Corrections.MatchFound)=0) 
    AND ((sp_CFQ_Coord_Corrections.MatchFound)=0) 
    AND ((CFQ_Coord_Corrections.RecImported)=1) 
    AND ((CFQ_Referrals.RecFileName)='COORDCORR_SPOINT') 
    AND ((CFQ_Referrals.RecCombKey)='No.Match') 
    AND ((sp_CFQ_Coord_Corrections.RecImported)=1));
    Error messages seen when executed:
    Msg 156, Level 15, State 1, Line 3
    Incorrect syntax near the keyword 'INNER'.
    Msg 102, Level 15, State 1, Line 10
    Incorrect syntax near 'CFQ_Coord_Corrections'.
    Please help.....

    Below is the query:
    UPDATE sp_CFQ_Coord_Corrections 
    INNER JOIN (CFQ_Coord_Corrections 
    INNER JOIN CFQ_Referrals ON CFQ_Coord_Corrections.CorrID = CFQ_Referrals.RecID) 
    ON sp_CFQ_Coord_Corrections.ID = CFQ_Referrals.RecID 
    SET CFQ_Coord_Corrections.MatchFound = 1, 
    CFQ_Coord_Corrections.RecTblID = [CFQ_Referrals].[RecTblID], 
    sp_CFQ_Coord_Corrections.MatchFound = 1
    WHERE (((CFQ_Coord_Corrections.MatchFound)=0) 
    AND ((sp_CFQ_Coord_Corrections.MatchFound)=0) 
    AND ((CFQ_Coord_Corrections.RecImported)=1) 
    AND ((CFQ_Referrals.RecFileName)='COORDCORR_SPOINT') 
    AND ((CFQ_Referrals.RecCombKey)='No.Match') 
    AND ((sp_CFQ_Coord_Corrections.RecImported)=1));
    Error messages seen when executed:
    Msg 156, Level 15, State 1, Line 3
    Incorrect syntax near the keyword 'INNER'.
    Msg 102, Level 15, State 1, Line 10
    Incorrect syntax near 'CFQ_Coord_Corrections'.
    Please help.....
    sp_CFQ_Coord_Corrections is a table and not a stored procedure.
    are these both tables "sp_CFQ_Coord_Corrections" and "CFQ_Coord_Corrections" different ??

  • Logical error in the query

    create table my_employee
    (id number(4)primary key,
    last_name varchar2(25),
    first_name varchar2(25),
    userid varchar2(8),
    salary number(9,2)
    I want to write an INSERT statement to MY_EMPLOYEE table . Concatenate the first letter of the first name and first seven characters of the last name to produce user ID using a single sql statement
    I wrote the query like this and i am getting logical error
    insert into my_employee
    values(&id,'&last_name','&first_name',substr('&&first_name',1,1)||substr('&last_name',1,7),&salary);
    SQL> insert into my_employee
    2 values(&id,'&last_name','&first_name',substr('&&first_name',1,1)||substr('&last_name',1,7),&sal
    ary);
    Enter value for id: 20
    Enter value for last_name: popopopp
    Enter value for last_name: qwertyyuu
    Enter value for salary: 300000
    old 2: values(&id,'&last_name','&first_name',substr('&&first_name',1,1)||substr('&last_name',1,7),
    new 2: values(20,'popopopp','o',substr('o',1,1)||substr('qwertyyuu',1,7),300000)
    1 row created.
    it is asking the last_name two times

    you can do it with a .sql script
    c:\my_emp.sql
    PROMPT
    PROMPT instering my_employees
    PROMPT
    ACCEPT ID NUMBER PROMPT 'ID ? : '
    ACCEPT FIRST_NAME CHAR PROMPT 'FIRST_NAME ?: '
    ACCEPT LAST_NAME CHAR PROMPT 'LAST_NAME ?: '
    ACCEPT SALARY NUMBER PROMPT 'SALARY ? : '
    insert into my_employee values(&id,'&last_name','&first_name',substr('&&first_name',1,1)||substr('&last_name',1,7),&salary);
    SELECT * FROM my_employee where id=&&id;
    and then from sqlplus @c:\my_emp.sql
    scott@ORCL> @C:\MY_EMP
    instering my_employees
    ID ? : 20
    FIRST_NAME ?: john
    LAST_NAME ?: papas
    SALARY ? : 1000
    old 1: insert into my_employee values(&id,'&last_name','&first_name',substr('&&first_name',1,1)||substr('&last_name',1,7),&salary)
    new 1: insert into my_employee values( 20,'papas','john',substr('john',1,1)||substr('papas',1,7), 1000)
    1 row created.
    old 1: SELECT * FROM my_employee where id=&&id
    new 1: SELECT * FROM my_employee where id= 20
    ID LAST_NAME FIRST_NAME USERID SALARY
    20 papas john jpapas 1000
    scott@ORCL>

  • Why am I getting a syntax error on the /head line in DW CC?

    I am getting a syntax error in DW CC.  Other threads have indicated this was a bug in CS6 but had been fixed in CC.  That leads me to believe it's my fault, but I can't figure it out.  Can anyone help based on the information I've pasted below?  Thanks!
    <!doctype html>
    <!--[if lt IE 7]> <html class="ie6 oldie"> <![endif]-->
    <!--[if IE 7]>    <html class="ie7 oldie"> <![endif]-->
    <!--[if IE 8]>    <html class="ie8 oldie"> <![endif]-->
    <!--[if gt IE 8]><!-->
    <html class="">
    <!--<![endif]-->
    <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>Untitled Document</title>
    <link href="boilerplate.css" rel="stylesheet" type="text/css">
    <link href="style.css" rel="stylesheet" type="text/css">
    <link href="jQueryAssets/jquery.ui.core.min.css" rel="stylesheet" type="text/css">
    <link href="jQueryAssets/jquery.ui.theme.min.css" rel="stylesheet" type="text/css">
    <link href="jQueryAssets/jquery.ui.accordion.min.css" rel="stylesheet" type="text/css">
    <link href="jQueryAssets/jquery.ui.tabs.min.css" rel="stylesheet" type="text/css">
    <!--
    To learn more about the conditional comments around the html tags at the top of the file:
    paulirish.com/2008/conditional-stylesheets-vs-css-hacks-answer-neither/
    Do the following if you're using your customized build of modernizr (http://www.modernizr.com/):
    * insert the link to your js here
    * remove the link below to the html5shiv
    * add the "no-js" class to the html tags at the top
    * you can also remove the link to respond.min.js if you included the MQ Polyfill in your modernizr build
    -->
    <!--[if lt IE 9]>
    <script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
    <![endif]-->
    <script src="respond.min.js"></script>
    <script src="jQueryAssets/jquery-1.8.3.min.js" type="text/javascript"></script>
    <script src="jQueryAssets/jquery-ui-1.9.2.accordion.custom.min.js" type="text/javascript"></script>
    <script src="jQueryAssets/jquery-ui-1.9.2.tabs.custom.min.js" type="text/javascript"></script>
    <!--The following script tag downloads a font from the Adobe Edge Web Fonts server for use within the web page. We recommend that you do not modify it.--><script>var __adobewebfontsappname__="dreamweaver"</script><script src="http://use.edgefonts.net/adamina:n4:default.js" type="text/javascript"></script>
    </head>
    <body>
    <div class="gridContainer clearfix">
      <div id="div1" class="fluid">
        <header id="header" class="fluid">
          <p><img src="Images/Logos/insidejoplinlogo.png"  alt=""/></p>
            <nav id="mainnav" class="fluid"> <ul class="fluid fluidList mainnavlist"> <li class="fluid mainnavitem zeroMargin_desktop"><a href="Index2.html" title="Inside Joplin Home" target="_self">Home</a></li><li class="fluid mainnavitem"><a href="news.html">News</a></li><li class="fluid mainnavitem"><a href="entertainment.html">Entertainment</a></li><li class="fluid mainnavitem"><a href="announcements.html">Announcements</a></li><li class="fluid mainnavitem hide_mobile"><a href="galleries.html">Galleries</a></li><li class="fluid mainnavitem hide_mobile"><a href="aboutcontact.html">About/Contact</a></li>  </ul> </nav>
        </header>
        <article id="indexguts" class="fluid">    <article id="indexarticle" class="fluid">
          <h4 class="fluid articleH4 zeroMargin_mobile">Latest News</h4>
          <p> </p>
         <div id="Accordion1">
            <h3><a href="#">Section 1</a></h3>
            <div>
              <p>Content 1</p>
              </div>
            <h3><a href="#">Section 2</a></h3>
            <div>
              <p>Content 2</p>
              </div>
            <h3><a href="#">Section 3</a></h3>
            <div>
              <p>Content 3</p>
              </div>
          </div>
        </article><article id="article1" class="fluid">
          <h4 class="fluid articleH4 zeroMargin_mobile">Latest Entertainment</h4>
          <p> </p>
          <div id="Accordion2">
            <h3><a href="#">Section 1</a></h3>
            <div>
              <p>Content 1</p>
              </div>
            <h3><a href="#">Section 2</a></h3>
            <div>
              <p>Content 2</p>
              </div>
            <h3><a href="#">Section 3</a></h3>
            <div>
              <p>Content 3</p>
              </div>
          </div>
        </article><article id="article2" class="fluid"><h4 class="fluid articleH4 zeroMargin_mobile">Latest Announcements</h4>
        <p> </p>
          <div id="Tabs1">
            <ul>
              <li><a href="#tabs-1">Obituaries</a></li>
              <li><a href="#tabs-2">Weddings</a></li>
              <li><a href="#tabs-3">More</a></li>
              </ul>
            <div id="tabs-1">
              <p>Content 1</p>
              </div>
            <div id="tabs-2">
              <p>Content 2</p>
              </div>
            <div id="tabs-3">
              <p>Content 3</p>
              </div>
        </div>
        </article><article id="indexbotleft" class="fluid">This is the content for Layout Article Tag "indexbotleft"</article><article id="article3" class="fluid">This is the content for Layout Article Tag "indexbotleft"</article></article><aside id="mainsidebar" class="fluid">This is the content for Layout Aside Tag "mainsidebar"</aside><aside id="mainsidebar2" class="fluid">This is the content for Layout Aside Tag "mainsidebar2"</aside><article id="indexbotrot" class="fluid">This is the content for Layout Article Tag "indexbotrot"</article>
        <footer id="footer" class="fluid">
        <nav id="footernav" class="fluid">
         <ul id="footernavlist" class="fluid fluidList"> <li class="fluid footernavlistitem zeroMargin_mobile"><a href="Index2.html">Home</a></li><li class="fluid footernavlistitem hide_mobile"><a href="news.html">News</a></li>
          <li class="fluid footernavlistitem hide_mobile"><a href="entertainment.html">Entertainment</a></li>
          <li class="fluid footernavlistitem hide_mobile"><a href="announcements.html">Announcements</a></li>
           <li class="fluid footernavlistitem zeroMargin_desktop zeroMargin_mobile"><a href="galleries.html">Galleries</a></li>
           <li class="fluid footernavlistitem zeroMargin_mobile"><a href="aboutcontact.html">About Us</a></li> 
            <li class="fluid footernavlistitem zeroMargin_mobile"><a href="mailto:[email protected]">Email</a></li> <li class="fluid footernavlistitem zeroMargin_mobile"><a href="www.facebook.com/insidejoplin" target="new">Facebook</a></li></ul> 
           </nav>
           <article id="footerarticle" class="fluid"><img src="Images/Logos/insidejoplinlogo.png"  alt=""/></article>
        </footer>
      </div>
    </div>
    +
    <script type="text/javascript">
    $(function() {
              $( "#Accordion1" ).accordion();
    $(function() {
              $( "#Accordion2" ).accordion();
    $(function() {
              $( "#Tabs1" ).tabs();
    </script>
    </body>
    </html>

    Well Jon, the code is very simple... it's generated by DW's form check... and, as i said, it happens with unfailing regularity the minute it's put in to a template generated child.
    This is what the code on the page looks like:
    <head>
    <!-- InstanceBeginEditable name="doctitle" -->
    <title>Title Here</title>
    <meta name="Keywords" content="some keywords here" />
    <meta name="Description" content="Description here" />
    <script type="text/javascript">
    function MM_validateForm() { //v4.0
      if (document.getElementById){
        var i,p,q,nm,test,num,min,max,errors='',args=MM_validateForm.arguments;
        for (i=0; i<(args.length-2); i+=3) { test=args[i+2]; val=document.getElementById(args[i]);
          if (val) { nm=val.name; if ((val=val.value)!="") {
            if (test.indexOf('isEmail')!=-1) { p=val.indexOf('@');
              if (p<1 || p==(val.length-1)) errors+='- '+nm+' must contain an e-mail address.\n';
            } else if (test!='R') { num = parseFloat(val);
              if (isNaN(val)) errors+='- '+nm+' must contain a number.\n';
              if (test.indexOf('inRange') != -1) { p=test.indexOf(':');
                min=test.substring(8,p); max=test.substring(p+1);
                if (num<min || max<num) errors+='- '+nm+' must contain a number between '+min+' and '+max+'.\n';
          } } } else if (test.charAt(0) == 'R') errors += '- '+nm+' is required.\n'; }
        } if (errors) alert('The following error(s) occurred:\n'+errors);
        document.MM_returnValue = (errors == '');
    </script>
    <!-- InstanceEndEditable -->
    </head>
    And, whammo: "There is a syntax error on line xx. Code hinting may not work until you fix this error."
    And, the error always highlights the closing </script> line.
    The script itself is fine:
    1. If one puts it into an external js file, there's no problem
    2. If one puts it in the body section, there's no problem
    3. If one puts it in the template, there's no problem
    Also, if one removes the closing </script> tag, the error goes away
    The problem only happens in a child generated by a template and in the location I've illustrated. Apparently, this is a problem a lot of users are facing...

  • Data Source 0HR_PA_0 Syntax Error in the start routine while activating

    Hi All,
    I have migrated the Business content for the data source 0HR_PA_0
    While activating the transformation-2 there is errors like:
    Start Routine: Syntax error in routine
    Rule (target: 0HDCNT_LAST, group: 01 Standard Group): Syntax error in routine
    Rule (target: 0AGE_KYF, group: 01 Standard Group): Syntax error in routine
    .................... etc
    I need help to resolve this issue.
    Thanks & Regards,
    Savitha

    Hello Jurgita,
    When Data Source was migrated the codes related to COMM_STRUCTURE was missing in the start routinue.
    Following codes (in bold) with regard to COMM_STRUCTURE added and then got activated
    4.     *--
    5.         COMM_STRUCTURE   type tys_sc_1__rule_25,
    6.         l_subrc          type sy-tabix,
    7.         l_abort          type sy-tabix,
    8.         ls_monitor       TYPE rsmonitor,
    9.         ls_monitor_recno TYPE rsmonitors.
    10.     
    11.       REFRESH:
    12.         MONITOR.
    13.     
    14.     * Runtime attributs
    15.         SOURCE_SYSTEM  = p_r_request->get_logsys( ).
    16.         move-corresponding SOURCE_FIELDS to COMM_STRUCTURE.
    17.     
    18.     *  Migrated update rule call
    19.       Perform routine_0011
    20.       using
    21.         COMM_STRUCTURE
    22.       CHANGING
    Regards,
    Savitha
    Edited by: Savitha  Ravi on Jun 19, 2009 6:34 AM

Maybe you are looking for

  • Query a List of Open WMI connections on a server from a remote system

    We are monitoring a specific windows service on a server using Sitescope remote monitoring. The sitescope system uses a WMI method to Check if the service on a specific server is up or not. Initially it works like a charm but over time the WMI connec

  • ITunes 10.6.3 freezing on my Mac

    Hi everyone, I have a Macbook (version 10.6.8). I can load up iTunes (version 10.6.3) just fine, and I can scroll through the library without any problems. However, as soon as I play a song, iTunes will freeze. What's weird is that the track will pla

  • Adcfgclone.pl dbTier ADX  connection error

    Hello, I got this error message in the Netservicehandler.log at the end of perl adcfgclone.pl dbTier. Platform config is as follows: Host: 64bit sun solaris apps: 11.5.9 db: 9.2.0 Log file follows:-- $ moreNetServiceHandler.logNetServiceHandler.log m

  • Sound Recorder with Wav sequence

    Hi I am lookin for sample code of sound recorder which displays the wav sequence while recording... something like Windows sound recorder... If Anyone knows... pls let me knw.. Thanks & Regards, Chandrakanth

  • Billing error: "Division" information missing

    Hi gurus, I need your help/guidance, please! When I am billing a sales order (VA01), I am getting an error: FI accounting document has not been created, because the "Division" value is missing. I have checked the sales order, and all the "Division" f