PowerShell command returned an exception. Unexpected token 's' in expression or statement

Hi All,
I am trying to Creating a VM based on a Template in VMM through Orchestrator Runbook using below URL;
http://blogs.catapultsystems.com/lrayl/archive/2013/07/03/orchestrator-system-center-integrations-part-3-creating-a-vm-based-on-a-template-in-vmm.aspx
Runbook:
But at the Create VM from Template activity runbook will failed:
Throwing below error in while running runbook in Error Summary text:
PowerShell command returned an exception. Unexpected token 's' in expression or statement.
Exception: InvalidOperationException
Target site: PSRunspaceInvoker.HandleInvokeException
Stack trace:
   at Microsoft.SystemCenter.Orchestrator.Integration.PowerShellConnector.PSRunspaceInvoker.HandleInvokeException(Exception ex, ILogger logger)
   at Microsoft.SystemCenter.Orchestrator.Integration.PowerShellConnector.PSRunspaceInvoker.Invoke(RunspaceInvoke runspace, String script, ILogger logger)
   at Microsoft.SystemCenter.Orchestrator.Integration.PowerShellConnector.PSScriptRunner.Execute(String script)
   at Microsoft.SystemCenter.Orchestrator.Integration.VMM2012Domain.VM.CloneFromTemplate(String vmmServer, ParameterList inputParameters)
   at Microsoft.SystemCenter.Orchestrator.Integration.VMM2012QIK.VM.CloneFromTemplate.DoExecute(IActivityRequest request, ILogger logger)
   at Microsoft.SystemCenter.Orchestrator.Integration.VMM2012QIK.ActivityBase`2.Execute(IActivityRequest request, IActivityResponse response)
Both Orchestrator & SCVMM powershell are set on Unrestricted powershell.
Kindly suggest any solution or work around for resolution.
Thanks Rahul$

This may be a bit late and perhaps not even relevant but I came across this post when trying to solve an issue I had with a powershell script in Orchestrator. Maybe it will help you, or maybe it will help someone else.
I was trying to create a connector between SCOM and our ticketing system. I wanted to export alert descriptions and in the process of testing I came across an alert description that had multiple lines and all kinds of crazy formatting. When I tried to assign
the Published Data to a varialbe in my powershell script i would get an error "Unexpected token [a partial alert description] in expression or statement.". After looking at the actual alert description data and seeing that i was only getting some of it
and not all of it it dawned on me that i somehow needed to escape out of all the crazy quoting, carriage returns, and special characters. to do that i assigned the Published Data to a variable in my powershell script as follows:
$Description = @"
{Description from "Get Alert"}
Apparently the @" "@ is called a here-string. Somewhat interesting. Hope it helps you or someone else!

Similar Messages

  • Powershell script returns the exception "Cannot index into a null array"

    Hi,
    $userName = $item["Editor"];
    $DocID = $item["_dlc_DocId"];
    Above lines on execution returns the below error.
    Cannot index into a null array.
    At C:\GetAllInvoices.PS1:23 char:26
    +           $userName = $item[ <<<< "Editor"];
        + CategoryInfo          : InvalidOperation: (Editor:String) [], RuntimeExc
       eption
        + FullyQualifiedErrorId : NullArray
    Cannot index into a null array.
    At C:\GetAllInvoices.PS1:24 char:30
    +               $DocID = $item[ <<<< "_dlc_DocId"];
        + CategoryInfo          : InvalidOperation: (_dlc_DocId:String) [], Runtim
       eException
        + FullyQualifiedErrorId : NullArray
    Any solution ?
    Thanks in advance,
    Dhileep

    The error indicates $item is either not an array or an empty array.
    Kind regards,
    Margriet Bruggeman
    Lois & Clark IT Services
    web site: http://www.loisandclark.eu
    blog: http://www.sharepointdragons.com

  • Bug in OC4J [unexpected token: IN] when use Subquery

    Hi
    I use this named query in my entity, but when I run it from JDeveloper 10.1.3.0.4 (SU2)
    it throw exception
    Thia is as sample query:
    @NamedQuery(name="EmpbyDept",query="SELECT object(o) FROM Employees o WHERE o.departments IN(SELECT object(d) FROM Departments d)")
    Internal Exception: Exception [TOPLINK-0] (Oracle TopLink - 10g Release 3 (10.1.3.0.0) (Build 060118)): oracle.toplink.exceptions.EJBQLException
    Exception Description: Syntax Recognition Problem parsing the EJBQL [SELECT object(o) FROM Employees o WHERE o.departments IN(SELECT object(d) FROM Departments d)]. The parser returned the following [unexpected token: IN]
    I looked in the Java Persistence API Proposed final for the In Expressions and it look like this:
    in_expression ::=state_field_path_expression [NOT] IN ( in_item {, in_item}* | subquery)
    in_item ::= literal | input_parameter
    Ghassan

    Hi Ghassan,
    At the moment we don't have a final date for the release, but we are hopeful to have a 10.1.3.1 Beta release very soon (in a few weeks), please keep watching the OTN space, and we will also announce it here in the forums.
    Thanks for your patience.
    Deepak

  • TotalVHDCapacity attribute is returning zero in "Get-SCVMTemplate | select Name, TotalVhdCapacity" powershell command though the Vhd capacity is 20 gb in size, vmm 2012 r2

    Hi All,
    TotalVHDCapacity attribute is returning zero in "Get-SCVMTemplate | select Name, TotalVhdCapacity" powershell command though the template has Vhd capacity is 20 gb in size, vmm 2012 r2. I can create VM using this template too.
    For other templates it is returning correct value though.
    Can anyone help us understanding the root cause and the solution too.
    Thanks in advance.
    Debabrata

    I booted this drive from another computer (Asrock M3A770DE mobo) and works fine, speed with dd was ~100MB/s
    I also update bios on my first computer with Intel D945GSEJT (there is selected AHCI mode) still the same transfers with dd (~10Mb/s)
    I have no idea what to do with it now
    EDIT:
    More tests with other hdd (Samsung HD502IJ), dd on mounted NTFS partition:
    Intel D945GSEJT booted from Archlinux iso:
    hdparm: ~75 MB/s
    dd: ~10 MB/s
    Intel D945GSEJT booted from Archlinux iso, HDD connected to PCI SATA controller (Promise 378):
    hdparm: ~60 MB/s
    dd: ~10 MB/s
    Asrock M3A770DE booted from Archlinux iso:
    hdparm: ~87 MB/s
    dd: ~76 MB/s
    Asrock M3A770DE booted from Archlinux iso, HDD connected to PCI SATA controller (Promise 378):
    hdparm: ~81MB/s
    dd: ~76 MB/s
    What is broken on D945GSEJT?
    Last edited by miskoala (2012-03-30 13:47:23)

  • EJB QL "unexpected token: ( " Exception with IN operator and AND operator

    Hey everyone,
    Hopefully someone can help me. I am just starting to write more complex queries with EJB QL and am running into an issue. When I run my query I get an "Internal Exception: line 1:87: unexpected token: (" Exception below is my query with acording to the sun references I have managed to find looks right. Here is my query:
    SELECT OBJECT(e) FROM Period e, IN (e.myScorecardItem.cyclesList) t WHERE current_date() BETWEEN e.startDate AND e.endDate AND t.id =?1
    I have removed the portion with the IN navigation and it works fine, and I have removed the conditional statement and left the IN portion and that works fine but I can not get the to work together. Here is my bean relationships: Cycles have ScorecardItems have Periods. I am trying to find all the Periods that fall within a certain cycle. Any direction or help anyone can provide would be greatly appreciated.
    Thanks,
    Justen

    It's not inherently bad - but it does depend on the optimizer getting  good estimate of the data volume.
    Did you test with 200 distinct values in your IN list, and can you see in the execution plan Oracle estimate of how many rows the subquery would generate.
    Regards
    Jonathan Lewis

  • Forms 10g compile : syntax error near unexpected token `in

    Hi,
    I am writing a code to compile FORMS 10g(10.1.2.0.2) in HP_UX one by one.
    this is the code---frm10g.sh
    *#!/bin/ksh*
    *# . ~oracle/forms/server/default.env*
    *# . sid icache*
    TERM=vt220
    *if [ $# != 2 ]*
    then
    echo Usage : $0 module_name module_type
    exit 1
    fi
    case $2 in
    FORM|form|F|f) ext1='fmb' ;ext='fmx' ; modtyp='FORM' ;;
    PLL|pll|p|lib|LIB) ext1='pll' ;ext='plx' ; modtyp='LIBRARY' ;;
    MENU|menu|M|m) ext1='mmb' ;ext='mmx' ; modtyp='MENU' ;;
    **) echo invalid parameter ; exit 1 ;*
    esac
    echo Generating $1.$ext
    frmcmp module=$1.$ext1 userid=abc/abc@abc output_file=../$1.$ext module_type=$modtyp batch=NO compile_all=special > ./log/$1.log
    when I try to excute above file frm10g.sh in command line i get following error. Please let me know how to fix it.
    [abc]u01/app/oracle/product/10.1.2/forms/forms/Forms10g:. frm10g.sh INV FORM
    : command not found
    : command not found
    'bash: ./frm10g.sh: line 13: syntax error near unexpected token `in
    'bash: ./frm10g.sh: line 13: `case $2 in
    I really aapreciate your help.
    Thanks
    Sandy

    Sandy,
    I must apologize. The Compile.sh does not come with the Oracle Dev Suite installation. However, the following is the contents of the compile.sh script we use. This script compiles a single form.
    #!/usr/bin/ksh
    ORACLE_HOME=/d01/oracle/ias1012;export ORACLE_HOME
    LD_LIBRARY_PATH=$ORACLE_HOME/lib:$ORACLE_HOME/lib32:$ORACLE_HOME/ctx/lib:/usr/java1.2/jre/lib/sparc:$ORACLE_HOME/jdk/jre/lib/sparc:/usr/lib:/usr/dt/lib:/usr/openwin/lib:/usr/ucblib:usr/ccs/lib; export LD_LIBRARY_PATH
    MODULE_NAME=`echo $1|cut -d. -f1`
    MODULE_SUFFIX=`echo $1|cut -d. -f2`
    MODULE_MESG=${2:-"Compiling $1"}
    OK_MESG=${3:-"  Compiled sucessfully"}
    . .setpass_cir
    APP_PW='cir/'`eimauth -g cir`'@database'
    echo "************************************************************************* "
    echo ${MODULE_MESG}
    frmcmp.sh module=/d01/oracle/forms/${MODULE_NAME}.fmb userid=${APP_PW} compile_all=yes batch=yes
    RC=$?
    case "$RC" in
      0)
        echo ${OK_MESG}
        echo "Compile errors, return code: $RC "
        cat ${MODULE_NAME}.err
        echo "Compile errors in $1, press [enter] to continue.\c"
        read x
    esac
    eval exit $RCYou should be able to modify this to suit your needs.
    Craig...

  • Unexpected Token '(' in expression or statement.

    I'm trying to retrieve DHCP server names and Leases using this script. But when I execute this section of the script of receive the following error message:
    Pwershell> C:\PowerShell\DHCPLease.ps1
    At C:\PowerShell\DHCPLease.ps1:287 char:25
    +  $line = $AllScopes[$i] (Read-Host " ").Split(",")
    +                         ~
    Unexpected token '(' in expression or statement.
        + CategoryInfo          : ParserError: (:) [], ParentContainsErrorRecordException
        + FullyQualifiedErrorId : UnexpectedToken
    Here is the part of the script that is failing
    #region Get all Scopes in the Server
    # Run the Command in the Show Scopes var
    $AllScopes=Invoke-Expression$ShowScopes
    # Go over all the Results, start from index 5 and finish in last index -3
    for($i=5;$i-lt$AllScopes.Length-3;$i++)
    # Split the line and get the strings
    $line=$AllScopes[$i](Read-Host"
    ").Split(",")  
    -   This is the line I receive the error
    $Scope.Address
    +=Check-Empty$line[0]
    $Scope.Mask
    +=Check-Empty$line[1]
    $Scope.State
    +=Check-Empty$line[2]
    # Line 3 and 4 represent the Name and Comment of the Scope
    # If the name is empty, try taking the comment
    If(Check-Empty$line[3]-eq"-")
    $Scope.Name
    +=Check-Empty$line[4]
    else{
    $Scope.Name
    +=Check-Empty$line[3]}

    That "read-host" seems weird, that cmdlet is supposed to be used to read input from a user typing into the console. Try changing this line
    $line = $AllScopes[$i] (Read-Host" ").Split(",")
    to this
    $line = $AllScopes[$i].Split(",")
    DJ Grijalva | MCITP: EMA 2007/2010 SPA 2010 | www.persistentcerebro.com

  • Execute powershell command (new-object -comObject ...) in management pack

    Hello everyone
    I have a COM Object that want to use it in my management pack. When I write the powershell command "new-object -comObject ... " to create it outside of MP and in a ps1 file it works without any error. However when I write it in my MP, this
    error is showed in event viewer: "Retrieving the COM class factory for component with CLSID {clsID} failed due to the following error: 80070005 Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))."
    I have to mention that when I use vb script in my MP and using "CreateObject()", I don't have any problem.
    How can I use "new-object -comObject ... " in my management pack?
    thank you all
    Alireza

    Hi Marthijn,
    Actually I don't have any problem with powershell in my management packs. For example I can use "MOM.ScriptAPI"
    to create $oBag and return it to next module. My problem is only with that custom COM object. Interesting thing is that, it
    works fine when I create it in powershell file outside of MP, but when I create it in my MP, that error occures.
    thank you so much
    Alireza

  • Unexpected token ''Test_Group (p)'' in expression or statement?

    Hi,
    I am trying to get a list of computers in each OU and get the count of each that are a member of the ''Test_Group (p)'' but I am getting the error "Unexpected token in expression or statement. Not sure what I am doing wrong here? I appreciate any help
    someone can give I am very new to powershell. Thank you
    import-module activedirectory
    foreach ($ou in Get-ADOrganizationalUnit -filter * -SearchScope 1){
    $computers = 0 + (get-adcomputer -filter * -searchbase $ou.distinguishedname).count
    $Test = get-adcomputer -Property * | where {$_.memberof 'Test_Group (p)'}
    $ou | add-member -membertype noteproperty -name Computers -value $computers -force
    $ou | select name,computers
    $Test | select name

    You may want to take some time to gain a level of proficiency with Powershell. Try this link for example: http://technet.microsoft.com/en-us/scriptcenter/dd793612.aspx then
    take some time to familiarize yourself with the features and capabilities of the ActiveDirectory module cmdlets. That will give you all the information you need.
    To see imported modules run:
    Get-Module
    To see available modules run:
    Get-Module -ListAvailable
    To see available cmdlets in a give module run:
    Get-Command -Module ActiveDirectory
    To get help on a specific cmdlet run:
    help Get-ADUser -Full
    Sam Boutros, Senior Consultant, Software Logic, KOP, PA http://superwidgets.wordpress.com (Please take a moment to Vote as Helpful and/or Mark as Answer, where applicable)

  • Syntax error near unexpected token `)'

    I get that error sometimes when i try to complile. I was trying to use my Banshee1.5.1 PKGBUILD on my desktop (it works on my laptop) and i got that error again. But i don't think it's banshee cause i remember getting that same error when i wanted to complile Gnote.
    Banshee
    checking for a BSD-compatible install... /bin/install -c
    checking whether build environment is sane... yes
    ./configure: eval: line 2650: unexpected EOF while looking for matching `''
    ./configure: eval: line 2651: syntax error: unexpected end of file
    configure: WARNING: `missing' script is too old or missing
    checking for a thread-safe mkdir -p... /bin/mkdir -p
    checking for gawk... gawk
    checking whether make sets $(MAKE)... yes
    checking how to create a ustar tar archive... gnutar
    checking whether to enable maintainer-specific portions of Makefiles... no
    checking whether NLS is requested... yes
    checking for style of include used by make... GNU
    checking for gcc... gcc
    checking for C compiler default output file name... a.out
    checking whether the C compiler works... yes
    checking whether we are cross compiling... no
    checking for suffix of executables...
    checking for suffix of object files... o
    checking whether we are using the GNU C compiler... yes
    checking whether gcc accepts -g... yes
    checking for gcc option to accept ISO C89... none needed
    checking dependency style of gcc... gcc3
    checking for intltool >= 0.35.0... 0.41.0 found
    checking for intltool-update... /usr/bin/intltool-update
    checking for intltool-merge... /usr/bin/intltool-merge
    checking for intltool-extract... /usr/bin/intltool-extract
    checking for xgettext... /usr/bin/xgettext
    checking for msgmerge... /usr/bin/msgmerge
    checking for msgfmt... /usr/bin/msgfmt
    checking for gmsgfmt... /usr/bin/msgfmt
    checking for perl... /usr/bin/perl
    checking for XML::Parser... ok
    checking build system type... i686-pc-linux-gnu
    checking host system type... i686-pc-linux-gnu
    checking for a sed that does not truncate output... /bin/sed
    checking for grep that handles long lines and -e... /bin/grep
    checking for egrep... /bin/grep -E
    checking for fgrep... /bin/grep -F
    checking for ld used by gcc... /usr/bin/ld
    checking if the linker (/usr/bin/ld) is GNU ld... yes
    checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B
    checking the name lister (/usr/bin/nm -B) interface... BSD nm
    checking whether ln -s works... yes
    checking the maximum length of command line arguments... 1572864
    checking whether the shell understands some XSI constructs... yes
    checking whether the shell understands "+="... yes
    checking for /usr/bin/ld option to reload object files... -r
    checking for objdump... objdump
    checking how to recognize dependent libraries... pass_all
    checking for ar... ar
    checking for strip... strip
    checking for ranlib... ranlib
    checking command to parse /usr/bin/nm -B output from gcc object... ok
    checking how to run the C preprocessor... gcc -E
    checking for ANSI C header files... yes
    checking for sys/types.h... yes
    checking for sys/stat.h... yes
    checking for stdlib.h... yes
    checking for string.h... yes
    checking for memory.h... yes
    checking for strings.h... yes
    checking for inttypes.h... yes
    checking for stdint.h... yes
    checking for unistd.h... yes
    checking for dlfcn.h... yes
    checking for objdir... .libs
    checking if gcc supports -fno-rtti -fno-exceptions... no
    checking for gcc option to produce PIC... -fPIC -DPIC
    checking if gcc PIC flag -fPIC -DPIC works... yes
    checking if gcc static flag -static works... yes
    checking if gcc supports -c -o file.o... yes
    checking if gcc supports -c -o file.o... (cached) yes
    checking whether the gcc linker (/usr/bin/ld) supports shared libraries... yes
    checking whether -lc should be explicitly linked in... no
    checking dynamic linker characteristics... GNU/Linux ld.so
    checking how to hardcode library paths into programs... immediate
    checking whether stripping libraries is possible... yes
    checking if libtool supports shared libraries... yes
    checking whether to build shared libraries... yes
    checking whether to build static libraries... yes
    checking for a BSD-compatible install... /bin/install -c
    checking for library containing strerror... none required
    checking for gcc... (cached) gcc
    checking whether we are using the GNU C compiler... (cached) yes
    checking whether gcc accepts -g... (cached) yes
    checking for gcc option to accept ISO C89... (cached) none needed
    checking dependency style of gcc... (cached) gcc3
    checking for ANSI C header files... (cached) yes
    checking for pkg-config... /usr/bin/pkg-config
    checking pkg-config is at least version 0.16... yes
    checking for GLIB - version >= 2.0.0... yes (version 2.22.2)
    checking for GDK_X11... yes
    checking for CLUTTER... yes
    checking for GST... yes
    checking for GST_PBUTILS... yes
    checking for BNPX_GTK... yes
    checking for X... libraries , headers
    checking for XVIDMODE... yes
    checking for MONO_MODULE... yes
    checking for gmcs... /usr/bin/gmcs
    checking for mono... /usr/bin/mono
    checking for Mono 2.0 GAC for System.Data.dll... found
    checking for Mono 2.0 GAC for System.Web.dll... found
    checking for Mono 2.0 GAC for System.Web.Services.dll... found
    checking for Mono 2.0 GAC for Mono.Cairo.dll... found
    checking for Mono 2.0 GAC for Mono.Posix.dll... found
    checking for Mono 2.0 GAC for ICSharpCode.SharpZipLib.dll... found
    checking for NDESK_DBUS_GLIB... yes
    checking for NDESK_DBUS... yes
    checking for MONO_ADDINS... yes
    checking for MONO_ADDINS_SETUP... yes
    checking for MONO_ADDINS_GUI... yes
    checking for NOTIFY_SHARP... yes
    checking for BOO... yes
    checking for monodocer... /usr/bin/monodocer
    checking for mdassembler... /usr/bin/mdassembler
    checking for NUNIT... no
    checking for NUNIT... yes
    checking for TAGLIB_SHARP... yes
    checking for GTKSHARP... yes
    checking for GLIBSHARP... yes
    checking for SQLITE... yes
    checking for GCONFSHARP... yes
    checking for GNOMESHARP... yes
    checking for gconftool-2... /usr/bin/gconftool-2
    Using config source xml:merged:/etc/gconf/gconf.xml.defaults for schema installation
    Using $(sysconfdir)/gconf/schemas as install directory for schema files
    checking for LIBMTP... yes
    checking for struct LIBMTP_track_struct.modificationdate... no
    checking for IPODSHARP... yes
    checking for KARMASHARP... no
    checking for MONO_ZEROCONF... yes
    checking locale.h usability... yes
    checking locale.h presence... yes
    checking for locale.h... yes
    checking for LC_MESSAGES... yes
    checking libintl.h usability... yes
    checking libintl.h presence... yes
    checking for libintl.h... yes
    checking for ngettext in libc... yes
    checking for dgettext in libc... yes
    checking for bind_textdomain_codeset... yes
    checking for msgfmt... (cached) /usr/bin/msgfmt
    checking for dcgettext... yes
    checking if msgfmt accepts -c... yes
    checking for gmsgfmt... (cached) /usr/bin/msgfmt
    checking for xgettext... (cached) /usr/bin/xgettext
    checking for catalogs to be installed... ar be@latin bg br ca cs da de dz en_CA en_GB es eu fi fr gl gu he hu it ja ko ky lt lv mk nb nl oc pa pl pt pt_BR ru sl sr sr@latin sv th uk vi zh_CN zh_HK zh_TW
    checking for sed... /bin/sed
    configure: creating ./config.status
    ./config.status: line 400: syntax error near unexpected token `)'
    ./config.status: line 400: ` *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;'
    Gnote
    checking for a BSD-compatible install... /bin/install -c
    checking whether build environment is sane... yes
    ./configure: eval: line 2411: unexpected EOF while looking for matching `''
    ./configure: eval: line 2412: syntax error: unexpected end of file
    configure: WARNING: `missing' script is too old or missing
    checking for a thread-safe mkdir -p... /bin/mkdir -p
    checking for gawk... gawk
    checking whether make sets $(MAKE)... yes
    checking whether to enable maintainer-specific portions of Makefiles... no
    checking whether ln -s works... yes
    checking for pkg-config... /usr/bin/pkg-config
    checking pkg-config is at least version 0.9.0... yes
    checking for g++... g++
    checking for C++ compiler default output file name... a.out
    checking whether the C++ compiler works... yes
    checking whether we are cross compiling... no
    checking for suffix of executables...
    checking for suffix of object files... o
    checking whether we are using the GNU C++ compiler... yes
    checking whether g++ accepts -g... yes
    checking for style of include used by make... GNU
    checking dependency style of g++... gcc3
    checking for gcc... gcc
    checking whether we are using the GNU C compiler... yes
    checking whether gcc accepts -g... yes
    checking for gcc option to accept ISO C89... none needed
    checking dependency style of gcc... gcc3
    checking how to run the C preprocessor... gcc -E
    checking for grep that handles long lines and -e... /bin/grep
    checking for egrep... /bin/grep -E
    checking for ANSI C header files... yes
    checking for sys/types.h... yes
    checking for sys/stat.h... yes
    checking for stdlib.h... yes
    checking for string.h... yes
    checking for memory.h... yes
    checking for strings.h... yes
    checking for inttypes.h... yes
    checking for stdint.h... yes
    checking for unistd.h... yes
    checking minix/config.h usability... no
    checking minix/config.h presence... no
    checking for minix/config.h... no
    checking whether it is safe to define __EXTENSIONS__... yes
    checking build system type... i686-pc-linux-gnu
    checking host system type... i686-pc-linux-gnu
    checking for a sed that does not truncate output... /bin/sed
    checking for fgrep... /bin/grep -F
    checking for ld used by gcc... /usr/bin/ld
    checking if the linker (/usr/bin/ld) is GNU ld... yes
    checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B
    checking the name lister (/usr/bin/nm -B) interface... BSD nm
    checking the maximum length of command line arguments... 1572864
    checking whether the shell understands some XSI constructs... yes
    checking whether the shell understands "+="... yes
    checking for /usr/bin/ld option to reload object files... -r
    checking for objdump... objdump
    checking how to recognize dependent libraries... pass_all
    checking for ar... ar
    checking for strip... strip
    checking for ranlib... ranlib
    checking command to parse /usr/bin/nm -B output from gcc object... ok
    checking for dlfcn.h... yes
    checking whether we are using the GNU C++ compiler... (cached) yes
    checking whether g++ accepts -g... (cached) yes
    checking dependency style of g++... (cached) gcc3
    checking how to run the C++ preprocessor... g++ -E
    checking for objdir... .libs
    checking if gcc supports -fno-rtti -fno-exceptions... no
    checking for gcc option to produce PIC... -fPIC -DPIC
    checking if gcc PIC flag -fPIC -DPIC works... yes
    checking if gcc static flag -static works... yes
    checking if gcc supports -c -o file.o... yes
    checking if gcc supports -c -o file.o... (cached) yes
    checking whether the gcc linker (/usr/bin/ld) supports shared libraries... yes
    checking whether -lc should be explicitly linked in... no
    checking dynamic linker characteristics... GNU/Linux ld.so
    checking how to hardcode library paths into programs... immediate
    checking whether stripping libraries is possible... yes
    checking if libtool supports shared libraries... yes
    checking whether to build shared libraries... yes
    checking whether to build static libraries... yes
    checking for ld used by g++... /usr/bin/ld
    checking if the linker (/usr/bin/ld) is GNU ld... yes
    checking whether the g++ linker (/usr/bin/ld) supports shared libraries... yes
    checking for g++ option to produce PIC... -fPIC -DPIC
    checking if g++ PIC flag -fPIC -DPIC works... yes
    checking if g++ static flag -static works... yes
    checking if g++ supports -c -o file.o... yes
    checking if g++ supports -c -o file.o... (cached) yes
    checking whether the g++ linker (/usr/bin/ld) supports shared libraries... yes
    checking dynamic linker characteristics... GNU/Linux ld.so
    checking how to hardcode library paths into programs... immediate
    checking for LIBGLIBMM... yes
    checking for GTK... yes
    checking for LIBGTKMM... yes
    checking for LIBXML... yes
    checking for LIBXSLT... yes
    checking for GCONF... yes
    checking for PCRE... yes
    checking uuid/uuid.h usability... yes
    checking uuid/uuid.h presence... yes
    checking for uuid/uuid.h... yes
    checking for uuid_unparse_lower in -luuid... yes
    checking for LIBPANELAPPLETMM... yes
    checking for GTKSPELL... yes
    checking for Boost headers version >= 103400... yes
    checking for Boost's header version... 1_39
    checking boost/bind.hpp usability... yes
    checking boost/bind.hpp presence... yes
    checking for boost/bind.hpp... yes
    checking boost/cast.hpp usability... yes
    checking boost/cast.hpp presence... yes
    checking for boost/cast.hpp... yes
    checking boost/lexical_cast.hpp usability... yes
    checking boost/lexical_cast.hpp presence... yes
    checking for boost/lexical_cast.hpp... yes
    checking for the toolset name used by Boost for g++... gcc44 -gcc
    checking boost/system/error_code.hpp usability... yes
    checking boost/system/error_code.hpp presence... yes
    checking for boost/system/error_code.hpp... yes
    checking for the Boost system library... yes
    checking boost/filesystem/path.hpp usability... yes
    checking boost/filesystem/path.hpp presence... yes
    checking for boost/filesystem/path.hpp... yes
    checking for the Boost filesystem library... yes
    checking boost/format.hpp usability... yes
    checking boost/format.hpp presence... yes
    checking for boost/format.hpp... yes
    checking boost/test/unit_test.hpp usability... yes
    checking boost/test/unit_test.hpp presence... yes
    checking for boost/test/unit_test.hpp... yes
    checking for the Boost unit_test_framework library... yes
    checking tr1/memory usability... yes
    checking tr1/memory presence... yes
    checking for tr1/memory... yes
    checking whether gcc understands -Wall... yes
    checking whether gcc understands -Wextra... yes
    checking whether gcc understands -Wsign-compare... yes
    checking whether gcc understands -Wpointer-arith... yes
    checking whether gcc understands -Wchar-subscripts... yes
    checking whether gcc understands -Wwrite-strings... yes
    checking whether gcc understands -Wunused... yes
    checking whether gcc understands -Wpointer-arith... yes
    checking whether gcc understands -Wshadow... yes
    checking whether gcc understands -fshow-column... yes
    checking whether NLS is requested... yes
    checking for intltool >= 0.35.0... 0.41.0 found
    checking for intltool-update... /usr/bin/intltool-update
    checking for intltool-merge... /usr/bin/intltool-merge
    checking for intltool-extract... /usr/bin/intltool-extract
    checking for xgettext... /usr/bin/xgettext
    checking for msgmerge... /usr/bin/msgmerge
    checking for msgfmt... /usr/bin/msgfmt
    checking for gmsgfmt... /usr/bin/msgfmt
    checking for perl... /usr/bin/perl
    checking for perl >= 5.8.1... 5.10.1
    checking for XML::Parser... ok
    checking locale.h usability... yes
    checking locale.h presence... yes
    checking for locale.h... yes
    checking for LC_MESSAGES... yes
    checking libintl.h usability... yes
    checking libintl.h presence... yes
    checking for libintl.h... yes
    checking for ngettext in libc... yes
    checking for dgettext in libc... yes
    checking for bind_textdomain_codeset... yes
    checking for msgfmt... (cached) /usr/bin/msgfmt
    checking for dcgettext... yes
    checking if msgfmt accepts -c... yes
    checking for gmsgfmt... (cached) /usr/bin/msgfmt
    checking for xgettext... (cached) /usr/bin/xgettext
    checking for gconftool-2... /usr/bin/gconftool-2
    Using config source xml:merged:/etc/gconf/gconf.xml.defaults for schema installation
    Using $(sysconfdir)/gconf/schemas as install directory for schema files
    checking for sed... /bin/sed
    configure: creating ./config.status
    ./config.status: line 400: syntax error near unexpected token `)'
    ./config.status: line 400: ` *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;'
    Both get exactly the same error.

    I have tried downgrading bash and gcc, but no luck. I have also looked into some config files and stuff but i can't find anything. Maybe it's time for a reinstall.

  • Unexpected Token: Error occuring inside a stored procedure

    I get an unexpected token error when trying to compile below stored procedure. The error occurs on the exec pk_proof.pr_ProofAssets execution statement inside the stored procedure. Any reason why?
    CREATE OR REPLACE PROCEDURE MONTHLY_ASSET (ln_business_dt_num IN NUMBER DEFAULT NULL,
                                               missing_tbl_name OUT NOCOPY VARCHAR2)
    IS
       ln_business_dt_num NUMBER;
       missing_tbl_name VARCHAR2;
       no_tbl_name_found EXCEPTION;
       bad_date_value EXCEPTION;
       counts_not_matched EXCEPTION;
    BEGIN
       IF ln_business_dt_num < 0 THEN
       RAISE bad_date_value;
       ELSE
         Select MAX(business_dt_num) into ln_business_dt_num
         FROM sasor.dp_ca_proof;
       if missing_tbl_name IS NOT NULL then
          raise no_tbl_name_found;
       end if;
       exec pk_proof.pr_ProofAssets('SLH_DST_ASSET', ln_business_dt_num, 'sasor_batch');

    EXEC (short for EXECUTE) is an SQL*Plus command. Just remove it.

  • Write PowerShell commands in C#

    Hi,
    I want to invoke powershell commands using C# from my wcf service. However, I keep getting the following error:
    An exception of type 'System.Management.Automation.ParameterBindingException' occurred in System.Management.Automation.dll but was not handled in user code
    The powershell script that I want to convert into C#:
    Get-VM -Name TestVM | FT State
    Here's what I wrote in my WCF Service in C#:
    PowerShell ps = PowerShell.Create();
    ps.AddCommand("Get-VM");
    ps.AddParameter("Name", "TestVM");
    ps.AddParameter("Format-Table");
    ps.AddParameter("State");
    var result = ps.Invoke();
    Can anyone point to me where I went wrong with the codings?
    Thanks. 

    After trying out for some time, I've managed to figure how to invoke it the way I want to.
    Here's the code of my WCF service:
    getStatus.VmName = "TestVM";
    string vmState = "";
    if (getStatus.VmName != "")
    PowerShell ps = PowerShell.Create();
    ps.AddCommand("Get-VM");
    ps.AddParameter("Name", getStatus.VmName.Trim());
    var result = ps.Invoke();
    foreach (PSObject r in result)
    VirtualMachineDetails vmInfo = new VirtualMachineDetails();
    vmInfo.VmStatus = r.Members["State"].Value.ToString();
    vmState = vmInfo.VmStatus;
    return vmState;
    It's quite simple actually it's just that I'm new to writing powershell codes in C#, thus it took much longer time to figure this out. Hope this will help others out there.

  • Execute powershell commands on a VM from the host.

    I’m wondering if it’s possible to execute PowerShell commands from the host that will be execute on a virtual machine.
    I have around 10 VM and I need to run the same command on all of it and I need to do the same in other 15 host.  
    None of the VM belong to the same domain.

    Yes, it's possible. 
    It's not recommended to do any administrative tasks from the host. You should remove the GUI and all roles from the host except things related to Hyper-V and used in your environment like Failover Clustering and MPIO. 
    As a best practice, set a Windows 8.1 VM as your management station and install RSAT tools on it including Hyper-V Manager. It also comes with Powershell modules you need to run Powershell commands and scripts against all your hosts and VMs.
    On the machines to be managed by Powershell you need to enable Powershell Remoting. In Server 2012 and above and Windows 8 and above this is enabled out of the box (even core versions). In older versions of Windows
    enable Powershell Remoting manually as shown in this post.
    On the management Win 8.1 VM that has RSAT installed, if the managed machines belong to the same domain as the managing station, you're good to go. If not, run this command on the managing station:
    winrm s winrm/config/client "@{TrustedHosts=""My2003Server,host2,host3,vm4""}"
    Execute your scripts against multiple machines by using Invoke-Command as in:
    'Computer1','Computer2','Computer3' | % {
    $Result = Invoke-Command -Computer $_ -ScriptBlock {
    Get-Process
    $Result
    This example, will execute the commands in the scriptblock on each of the 3 computers in line1, and return the result.
    For more information see
    Don Jones' Secrets of Powershell Remoting eBook.
    Sam Boutros, Senior Consultant, Software Logic, KOP, PA http://superwidgets.wordpress.com (Please take a moment to Vote as Helpful and/or Mark as Answer, where applicable) _________________________________________________________________________________
    Powershell: Learn it before it's an emergency http://technet.microsoft.com/en-us/scriptcenter/powershell.aspx http://technet.microsoft.com/en-us/scriptcenter/dd793612.aspx

  • Error while Seq vlc in powershell command line.

    Hi Team,
    when i am trying to seq Vlc i got below error in power shell.
    i have entered below command lines in powershell
    1. cd c:\install
    2. Set-ExecutionPolicy Unrestricted
    3. New-AppvSequencerPackage -FullLoad -Installer "C:\Install\vlc-2.1.3-win32.exe" -Name "Unknown_VLC_2.1.3_01_W7_32_A" -Pa
    th C:\Packages -PrimaryVirtualApplicationDirectory "C:\Windows" -TemplateFilePath .\AppV5SequencerTemplate.appvt -Verbo
    se
    after it's called "C:\Install\vlc-2.1.3-win32.exe", i did default install and clicked close button.
    after 5 mint's i got below error.
    could you please help me to solve.
    1. AppV5SequencerTemplate.appvt file present in c:\installer folder
    2. c:\packages folder created
    Thanks in Advance :)
    Ramesh
    PS C:\Install> New-AppvSequencerPackage -FullLoad -Installer "C:\Install\vlc-2.1.3-win32.exe" -Name "Unknown_VLC_2.1.3_01_W7_32_A" -Pa
    th C:\Packages -PrimaryVirtualApplicationDirectory "C:\Windows" -TemplateFilePath .\AppV5SequencerTemplate.appvt -Verbo
    se
    Unhandled Exception: System.AccessViolationException: Attempted to read or write protected memory. This is often an indi
    cation that other memory is corrupt.
    at PE.ComputeMinFileRanges(PE* )
    at ResolveDependencies(IPackageFile file, IEnumerable`1 files, Func`4 fnGetDependencyPathFromName, Func`2 fnGetLocalP
    athOfPackageFile, HashSet`1 dependencies, HashSet`1 visited)
    at Microsoft.ApplicationVirtualization.Packaging.PEScanner.BuildDependencies(IEnumerable`1 allPackageFiles, Func`2 pr
    edicate, Func`4 fnGetDependencyPathFromName, Func`2 fnGetLocalPathOfPackageFile)
    at Microsoft.ApplicationVirtualization.Packaging.StaticDependencyPackagingSubsystem.<>c__DisplayClass8.<.ctor>b__0(Ob
    ject sender, CommonPreEventArgs args)
    at System.EventHandler`1.Invoke(Object sender, TEventArgs e)
    at Microsoft.ApplicationVirtualization.Packaging.PackagingEngine.OnFinalizePackage(Func`1 writerFactory)
    at Microsoft.ApplicationVirtualization.Packaging.PackagingEngine.<>c__DisplayClass18.<FinalizePackage>b__12()
    at Microsoft.ApplicationVirtualization.Packaging.WithAppCorruptionCheck.Execute(Action execute, Action`1 logCorruptio
    n)
    at Microsoft.ApplicationVirtualization.Packaging.WithAppCorruptionCheck.Execute(Action execute)
    at Microsoft.ApplicationVirtualization.Packaging.PackagingEngine.<>c__DisplayClass18.<FinalizePackage>b__11()
    at Microsoft.ApplicationVirtualization.Packaging.ExceptionGuard`1.Guard(Action logStart, Action execute, Action logEn
    d, Action`1 exceptionAction)
    at Microsoft.ApplicationVirtualization.Packaging.PackagingEngine.FinalizePackage(Func`1 writerFactory)
    at Microsoft.ApplicationVirtualization.Packaging.Packager.FinalizePackage(IPackageFiles packageFiles, String manifest
    Path, String registryHivePath, String streamMapPath, String packageHistoryPath, String installPath, String installShortP
    ath, String packagePath, CompressionOption compression, Predicate`1 addFileToPublishingFeatureBlock, PackagingEngineType
    engineType, PackagerParameters packageParameters)
    at Microsoft.ApplicationVirtualization.Packaging.Sequencing.PackagerAdapter.FinalizePackage(IPackageFiles packageFile
    s, String manifestPath, String registryHivePath, String streamMapPath, String packageHistoryPath, String installPath, St
    ring packagePath, CompressionOption compression, PackagerParameters packagerParameters)
    at Microsoft.ApplicationVirtualization.Packaging.Sequencing.PackagerOrchestrator.FinalizePackage(String streamMapPath
    , String packagePath, String manifestPath, String registryHivePath, String packageHistoryPath, String installPath, Compr
    essionOption compression, Boolean toAppendVersionNumberToFileName, PackagerParameters packagerParameters)
    at Microsoft.AppV.Modernizer.Cmdlets.NewAppvSequencerPackage.CreatePackageViaInstaller(String packageName, String out
    putDirectoryPath, String primaryApplicationVirtualDirectory, String installer, String templatePath, Boolean fullLoad, Fu
    nc`1 fnSequencerFactory, Func`2 fnMonitoringSessionManagerFactory, Func`1 fnSequencerStateFactory, Func`2 fnTaskScannerA
    dapterFactory, Func`2 fnPackagerOrchestratorFactory, Func`1 fnSequencerTemplateFactory, Func`2 fnExclusionListFactory, A
    ction`1 fnWait, Action fnConfigurePrivileges, Func`2 fnOutputDirectoryExists, Func`2 fnOutputSubdirExists, Action`1 fnCr
    eateDirectory)
    at Microsoft.AppV.Modernizer.Cmdlets.NewAppvSequencerPackage.CreatePackageViaInstaller(String packageName, String out
    putDirectoryPath, String primaryApplicationVirtualDirectory, String installer, String templatePath, Boolean fullLoad)
    at Microsoft.AppV.Modernizer.Cmdlets.NewAppvSequencerPackage.NewPackage()
    at Microsoft.AppV.Modernizer.Cmdlets.NewAppvSequencerPackage.<ProcessRecord>b__1()
    at Microsoft.AppV.Modernizer.Cmdlets.ExceptionGuard.Guard(Action logStart, Action execute, Action logEnd, Action`1 er
    rorAction)
    at Microsoft.AppV.Modernizer.Cmdlets.NewAppvSequencerPackage.ProcessRecord()
    at System.Management.Automation.CommandProcessor.ProcessRecord()
    at System.Management.Automation.CommandProcessorBase.DoExecute()
    at System.Management.Automation.Internal.PipelineProcessor.SynchronousExecuteEnumerate(Object input, Hashtable errorR
    esults, Boolean enumerate)
    at System.Management.Automation.PipelineOps.InvokePipeline(Object input, Boolean ignoreInput, CommandParameterInterna
    l[][] pipeElements, CommandBaseAst[] pipeElementAsts, CommandRedirection[][] commandRedirections, FunctionContext funcCo
    ntext)
    at System.Management.Automation.Interpreter.ActionCallInstruction`6.Run(InterpretedFrame frame)
    at System.Management.Automation.Interpreter.EnterTryCatchFinallyInstruction.Run(InterpretedFrame frame)
    at System.Management.Automation.Interpreter.EnterTryCatchFinallyInstruction.Run(InterpretedFrame frame)
    at System.Management.Automation.Interpreter.Interpreter.Run(InterpretedFrame frame)
    at System.Management.Automation.Interpreter.LightLambda.RunVoid1[T0](T0 arg0)
    at System.Management.Automation.ScriptBlock.InvokeWithPipeImpl(ScriptBlockClauseToInvoke clauseToInvoke, Boolean crea
    teLocalScope, Dictionary`2 functionsToDefine, List`1 variablesToDefine, ErrorHandlingBehavior errorHandlingBehavior, Obj
    ect dollarUnder, Object input, Object scriptThis, Pipe outputPipe, InvocationInfo invocationInfo, Object[] args)
    at System.Management.Automation.ScriptBlock.<>c__DisplayClassa.<InvokeWithPipe>b__8()
    at System.Management.Automation.Runspaces.RunspaceBase.RunActionIfNoRunningPipelinesWithThreadCheck(Action action)
    at System.Management.Automation.ScriptBlock.InvokeWithPipe(Boolean useLocalScope, Dictionary`2 functionsToDefine, Lis
    t`1 variablesToDefine, ErrorHandlingBehavior errorHandlingBehavior, Object dollarUnder, Object input, Object scriptThis,
    Pipe outputPipe, InvocationInfo invocationInfo, Object[] args)
    at System.Management.Automation.ScriptBlock.InvokeUsingCmdlet(Cmdlet contextCmdlet, Boolean useLocalScope, ErrorHandl
    ingBehavior errorHandlingBehavior, Object dollarUnder, Object input, Object scriptThis, Object[] args)
    at Microsoft.PowerShell.Commands.InvokeExpressionCommand.ProcessRecord()
    at System.Management.Automation.CommandProcessor.ProcessRecord()
    at System.Management.Automation.CommandProcessorBase.DoExecute()
    at System.Management.Automation.Internal.PipelineProcessor.SynchronousExecuteEnumerate(Object input, Hashtable errorR
    esults, Boolean enumerate)
    at System.Management.Automation.PipelineOps.InvokePipeline(Object input, Boolean ignoreInput, CommandParameterInterna
    l[][] pipeElements, CommandBaseAst[] pipeElementAsts, CommandRedirection[][] commandRedirections, FunctionContext funcCo
    ntext)
    at System.Management.Automation.Interpreter.ActionCallInstruction`6.Run(InterpretedFrame frame)
    at System.Management.Automation.Interpreter.EnterTryCatchFinallyInstruction.Run(InterpretedFrame frame)
    at System.Management.Automation.Interpreter.EnterTryCatchFinallyInstruction.Run(InterpretedFrame frame)
    at System.Management.Automation.Interpreter.Interpreter.Run(InterpretedFrame frame)
    at System.Management.Automation.Interpreter.LightLambda.RunVoid1[T0](T0 arg0)
    at System.Management.Automation.DlrScriptCommandProcessor.RunClause(Action`1 clause, Object dollarUnderbar, Object in
    putToProcess)
    at System.Management.Automation.CommandProcessorBase.DoComplete()
    at System.Management.Automation.Internal.PipelineProcessor.DoCompleteCore(CommandProcessorBase commandRequestingUpstr
    eamCommandsToStop)
    at System.Management.Automation.Internal.PipelineProcessor.SynchronousExecuteEnumerate(Object input, Hashtable errorR
    esults, Boolean enumerate)
    at System.Management.Automation.PipelineOps.InvokePipeline(Object input, Boolean ignoreInput, CommandParameterInterna
    l[][] pipeElements, CommandBaseAst[] pipeElementAsts, CommandRedirection[][] commandRedirections, FunctionContext funcCo
    ntext)
    at System.Management.Automation.Interpreter.ActionCallInstruction`6.Run(InterpretedFrame frame)
    at System.Management.Automation.Interpreter.EnterTryCatchFinallyInstruction.Run(InterpretedFrame frame)
    at System.Management.Automation.Interpreter.EnterTryCatchFinallyInstruction.Run(InterpretedFrame frame)
    at System.Management.Automation.Interpreter.Interpreter.Run(InterpretedFrame frame)
    at System.Management.Automation.Interpreter.LightLambda.RunVoid1[T0](T0 arg0)
    at System.Management.Automation.DlrScriptCommandProcessor.RunClause(Action`1 clause, Object dollarUnderbar, Object in
    putToProcess)
    at System.Management.Automation.CommandProcessorBase.DoComplete()
    at System.Management.Automation.Internal.PipelineProcessor.DoCompleteCore(CommandProcessorBase commandRequestingUpstr
    eamCommandsToStop)
    at System.Management.Automation.Internal.PipelineProcessor.SynchronousExecuteEnumerate(Object input, Hashtable errorR
    esults, Boolean enumerate)
    at System.Management.Automation.Runspaces.LocalPipeline.InvokeHelper()
    at System.Management.Automation.Runspaces.LocalPipeline.InvokeThreadProc()
    at System.Management.Automation.Runspaces.PipelineThread.WorkerProc()
    at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object
    state, Boolean preserveSyncCtx)
    at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, B
    oolean preserveSyncCtx)
    at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
    at System.Threading.ThreadHelper.ThreadStart()
    PS C:\Install>

    Thanks for your replay
    i have re- seq'd it's working..
    Thanks
    Er Reddy

  • TO_DATE function with JPA, Getting Unexpected Token error

    I am constructing a search query like this from my JAVA code
    SELECT * FROM EMAIL_PROXY_ERROR_LOG WHERE (to_date((REPLACE (DATETIME,'T',':')),'yyyy-mm-dd:hh24:mi:ss') BETWEEN to_date('2008-04-29:11:30:08','yyyy-mm-dd:hh24:mi:ss') AND to_date('2008-04-30:11:30:02','yyyy-mm-dd:hh24:mi:ss'))
    I am using Toplink Essentials and I get the following error while running, what would be a possible solution
    Exception Description: Syntax error parsing the query [select c FROM EmailProxyErrorLog c WHERE to_date((REPLACE (c.dateTime,'T',':')),'yyyy-mm-dd:hh24:mi:ss') BETWEEN to_date('2008-04-26:11:30:08','yyyy-mm-dd:hh24:mi:ss') AND to_date('2008-04-30:11:30:02','yyyy-mm-dd:hh24:mi:ss')], line 1, column 42: unexpected token [to_date].
    Internal Exception: line 1:42: unexpected token: to_date
    at oracle.toplink.essentials.exceptions.EJBQLException.unexpectedToken(EJBQLException.java:389)
    at oracle.toplink.essentials.internal.parsing.ejbql.EJBQLParser.handleANTLRException(EJBQLParser.java:350)
    at oracle.toplink.essentials.internal.parsing.ejbql.EJBQLParser.addError(EJBQLParser.java:278)
    at oracle.toplink.essentials.internal.parsing.ejbql.EJBQLParser.reportError(EJBQLParser.java:378)
    at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.arithmeticPrimary(EJBQLParser.java:3617)
    at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.arithmeticFactor(EJBQLParser.java:3513)
    at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.arithmeticTerm(EJBQLParser.java:3407)
    at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.simpleArithmeticExpression(EJBQLParser.java:1021)
    at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.arithmeticExpression(EJBQLParser.java:2304)
    at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.simpleConditionalExpression(EJBQLParser.java:2282)
    at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.conditionalPrimary(EJBQLParser.java:2218)
    at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.conditionalFactor(EJBQLParser.java:2155)
    at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.conditionalTerm(EJBQLParser.java:2030)
    at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.conditionalExpression(EJBQLParser.java:1989)
    at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.whereClause(EJBQLParser.java:507)
    at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.selectStatement(EJBQLParser.java:184)
    at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.document(EJBQLParser.java:135)
    at oracle.toplink.essentials.internal.parsing.ejbql.EJBQLParser.parse(EJBQLParser.java:166)
    at oracle.toplink.essentials.internal.parsing.ejbql.EJBQLParser.buildParseTree(EJBQLParser.java:127)
    at oracle.toplink.essentials.internal.ejb.cmp3.base.EJBQueryImpl.buildEJBQLDatabaseQuery(EJBQueryImpl.java:215)
    at oracle.toplink.essentials.internal.ejb.cmp3.base.EJBQueryImpl.buildEJBQLDatabaseQuery(EJBQueryImpl.java:189)
    at oracle.toplink.essentials.internal.ejb.cmp3.base.EJBQueryImpl.buildEJBQLDatabaseQuery(EJBQueryImpl.java:153)
    at oracle.toplink.essentials.internal.ejb.cmp3.base.EJBQueryImpl.<init>(EJBQueryImpl.java:114)
    at oracle.toplink.essentials.internal.ejb.cmp3.base.EJBQueryImpl.<init>(EJBQueryImpl.java:99)
    at oracle.toplink.essentials.internal.ejb.cmp3.EJBQueryImpl.<init>(EJBQueryImpl.java:86)
    at oracle.toplink.essentials.internal.ejb.cmp3.EntityManagerImpl.createQuery(EntityManagerImpl.java:204)
    Caused by: line 1:42: unexpected token: to_date
    at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.arithmeticPrimary(EJBQLParser.java:3611)

    Hello,
    The JPQL dies not define a to_date function, which is why it will throw an exception when parsing the query string. You will need to use a native query for this if you need to convert database fields to dates for comparison.
    Best Regards,
    Chris

Maybe you are looking for

  • I was wondering if there is a tutorial on how to make a blog page in muse?

    I was wondering if there is a tutorial on how to make a blog page in muse? Any help will be appreciated.

  • I need thumbnail images

    I have some 640X480 images and I need to create "thumbnails" of these images for uploading to my website. It's for a shopping cart and it is my understanding that I have to have two copies of the same image. The original 640X480 and then the smaller

  • Camera Raw 7.3 prblem

    Since I have updated to Camera Raw 7.3, I can only process 1-3 files before it stops working. (Vista SP2, 4 gig mem). I never had a problem with 7.2 and would like to revert to that update. Can it be done, if so, how?

  • Printout different than print preview - MacBook Pro & HP Photosmart 3310

    I am creating photocards on 8 1/2 X 11 photocard paper on HP3310 printer. The goal is to have the photo on the bottom half of the paper with the printout to the edges (borderless); the card is then folded in half. The actual image printed is cropped

  • When to apply SP 3 Patches for BO XI R3.1 Enterprise

    Dear Experts, I have installed BO XI R3.1 Enterprise Version.Xcelsius 2008 also. I want to work on them now. Later can i apply SP 3 patches for them or i need to apply at initial stages only. Thanks