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

can't I call a function this way?

Participant ,
Apr 06, 2012 Apr 06, 2012

Copy link to clipboard

Copied

I tried to get records from a table from server A (Sybase) and insert the records to server B (Oracle) using CF8

Both has the same exact table and datatype

When I do the following, I got this error and not sure where I did wrong

Missing argument name.

When using named parameters to a function, every parameter must have a name.

The CFML compiler was processing:

My codes:

--------------

<cfquery name="getSybaseRec" datasource="DSN1">

  SELECT * FROM tbl_EP

</cfquery>

<CFLOOP query="getSybaserec">

    <CFSET ToOra ('#Column_1#', '#Column_2#', '#CreateODBCDate(DateColumn)#'>

</CFLOOP>

<CFFUNCTION name = "ToOra">

  <cfargument name="col1" type="String" required="True">

  <cfargument name="col2" type="String" required="True">

  <cfargument name="date_col" type="date" required="True">

  INSERT INTO tblEP_Ora (Column_1, Column_2, DateColumn)

   VALUES ('#arguments.col1#', '#arguments.col2#', #arguments.date_col#>

</CFFUNCTION>

TOPICS
Getting started

Views

1.5K

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
Valorous Hero ,
Apr 06, 2012 Apr 06, 2012

Copy link to clipboard

Copied

LATEST

Unless it is a copy paste error, you are missing close parenthesis ")" in the cfset and INSERT (as well as cfquery tags).

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