Announcement

Collapse
No announcement yet.

[SOLVED] Need help !!!!

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • [SOLVED] Need help !!!!

    Hello,

    Can anybody help me to fixe this problem ??
    I create a Project Librairy with a Function called UTLecParam :

    <?php
    function UTLecParam(){
    $requete = "SELECT cnom, cvaleur FROM tparamet";
    sc_lookup(rs_params, $requete, conn_mysql);
    foreach({rs_params} as $rec){
    echo "rec ".$rec[0]." ".$rec[1]." ".$rec[2];
    }
    return true;
    }
    ?>

    In a Blank application I write this :

    $ok = UTLecParam();


    But I receive this error message :

    Parse error: syntax error, unexpected ',' in c:\...\test.php on line 801

    the generated php file :

    function UTLecParam($trt){
    ....
    798 $_SESSION['scriptcase']['grid_reser']['contr_erro'] = 'on';
    799
    800 $requete = "SELECT cnom, cvaleur FROM tparamet";
    801
    802 $nm_select = $requete, conn_mysql;
    803 $_SESSION['scriptcase']['sc_sql_ult_comando'] = $nm_select;
    ...

    Thanks !!!
    Nacyil

  • #2
    $nm_select = $requete, conn_mysql;

    Here's a comma which is not ok.

    Have you selected your librarie to be included in your application? (application -> libraries)
    Albert Drent
    aducom software netherlands
    scriptcase partner, reseller, support and (turn-key) development
    www.scriptcase.eu / www.scriptcase.nl

    Comment


    • #3
      Hi,

      Yes, my library is selected !!!

      Comment


      • #4
        I think, I have to use this sc_lookup(rs_params, $requete) without connection parameter , but in this case in receive an error message ... ini::$db
        I also try with sc_select command, it's the same !!

        strange ??

        Comment


        • #5
          Hi,
          your connection parameter has to be in quotes.

          sc_lookup(rs_params, $requete,"conn_mysql");

          Take care
          jsb

          Comment


          • #6
            SAVED !!!

            Thanks jsbinca !!!

            Comment

            Working...
            X