Announcement

Collapse
No announcement yet.

Snapshot error

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

    Snapshot error

    I have a php block which connects to the database to populate a drop down list. Since i have added this code (see code below) when i try to export a snapshot i get an error (also below) which indicates that the database is open. However i am able to compact the database.

    PHP Block:
    Code:
    <actinic:block php="true" >
        $connect = odbc_connect("ActinicCatalog8","","");
        $query = "SELECT [sName] FROM [Customer] ORDER BY [sName] ASC";
        $result = odbc_exec($connect, $query);
            while(odbc_fetch_row($result)){
                $nCustomer = odbc_result($result, 1);
              	echo '<option value="'.$nCustomer.'">'.$nCustomer.'</option>';
            }
        odbc_close($connect);
    </actinic:block>
    Fatal error when exporting a snapshot:
    FATAL ERRORS
    (File SnapshotWizard.cpp, Line 674) - Archive error 5 - The compression operation failed
    Library error - Can not open file C:\actinic_sites\Site1\ActinicCatalog.mdb ! has been caught.
    Any ideas how to fix this?
    Thanks.

    #2
    I was getting a problem when I tried to take a snapshot - but a different error - anyway I found compacting the database in Access rather than via Actinic sorted out the problem.
    Jane Thurnell-Read
    200 Plus Weight Loss Tips

    500 Plus Health And Happiness Tips

    Comment


      #3
      Originally posted by janeread
      I was getting a problem when I tried to take a snapshot - but a different error - anyway I found compacting the database in Access rather than via Actinic sorted out the problem.
      Thanks, i've seen the error before too and i fixed it by compacting the database. However this time it seems to be directly related to that piece of PHP code. The php code is performing as it's expected/required so i'd like to use it but not if it means i can't take a snapshot

      Comment


        #4
        Whenever we see
        ActinicCatalog.mdb ! has been caught.
        we always recommend closing and reopening Actinic to resolve it.
        It usually indicates that Windows JET ODBC drivers has its knickers in a bit of a twist about who has the active open connection to the Actinic database.
        Fergus Weir - teclan ltd
        Ecommerce Digital Marketing

        SellerDeck Responsive Web Design

        SellerDeck Hosting
        SellerDeck Digital Marketing

        Comment


          #5
          we always recommend closing and reopening Actinic to resolve it
          I have restarted Actinic several times as in the case of any error its the 1st step... Likewise i have rebooted the machine, compacted the database etc...

          However it still remains that the only fix is to remove the block of php code which accesses the database. I would love if someone could shed light on why my php code is causing this error?

          As before my php code:
          Code:
           <actinic:block php="true" >
              $connect = odbc_connect("ActinicCatalog8","","");
              $query = "SELECT [sName] FROM [Customer] ORDER BY [sName] ASC";
              $result = odbc_exec($connect, $query);
                  while(odbc_fetch_row($result)){
                      $nCustomer = odbc_result($result, 1);
                    	echo '<option value="'.$nCustomer.'">'.$nCustomer.'</option>';
                  }
              odbc_close($connect);
          </actinic:block>
          Thanks.

          Comment


            #6
            I think it is something to do with actinic needing exclusive rights to the database and not prepared to share. Bit like a spoilt child actually, picture actinic sitting in a pram throwing toys out if php comes along and tries to join the party.

            Comment


              #7
              Lol at your description of Actinic Lee! Is there a solution, other than commenting out that code every time i want to take a snapshot

              Comment


                #8
                There have been some posts in this area of late and i am speaking from what i learnt in reading them rather than personal knowledge, buggered if i could direct you to the threads though, just part of the daily read, in the last 2 weeks though definitely. If commenting out is the only solution then you could have a much quicker solution and have a flag in site options saying show = yes or no and then a blockif around the code either adding it or not. Bit like a php switch then.

                Apologies for the grey reply, not an area of real knowledge for me.

                Gabe or Jan your best bet in this area me thinks.

                Comment


                  #9
                  Norman and Gabirel have both discussed this crashing issue.

                  http://community.actinic.com/showthread.php?t=32815

                  You could try dropping this code into your actinic_main.php as a function and calling this function from within a php codeblock. This has worked for other PHP database querying.
                  Fergus Weir - teclan ltd
                  Ecommerce Digital Marketing

                  SellerDeck Responsive Web Design

                  SellerDeck Hosting
                  SellerDeck Digital Marketing

                  Comment

                  Working...
                  X