Don"t get all records from SQL-table

Don"t get all records from SQL-table

am 24.09.2007 10:11:50 von LK

Hi!

Following script stops after a while (appr. 1 minute) without an error-
message:

// Loop 12 Times:
$conn=odbc_connect("database1","","");
$sql="SELECT * FROM Table1 WHERE id>0";
$result = odbc_exec($conn, $sql);
$i=1;
while (odbc_fetch_row($result, $i)){
// --- Creating table for display ---
$i++;
};

With reading 3000 records, looping 12 times. With the loop ~ 1 to 3
times the script works.

Is there any timeout-problem (session- and script-timeout are set to
1000)?

Regards
LK

Re: Don"t get all records from SQL-table

am 24.09.2007 10:41:54 von Courtney

LK wrote:
> Hi!
>
> Following script stops after a while (appr. 1 minute) without an error-
> message:
>
> // Loop 12 Times:
> $conn=odbc_connect("database1","","");
> $sql="SELECT * FROM Table1 WHERE id>0";
> $result = odbc_exec($conn, $sql);
> $i=1;
> while (odbc_fetch_row($result, $i)){
> // --- Creating table for display ---
> $i++;
> };
>
> With reading 3000 records, looping 12 times. With the loop ~ 1 to 3
> times the script works.
>
> Is there any timeout-problem (session- and script-timeout are set to
> 1000)?
>
> Regards
> LK
>
A wild guess: Runs out of memory somewhere..

Re: Don"t get all records from SQL-table

am 24.09.2007 10:41:54 von Courtney

LK wrote:
> Hi!
>
> Following script stops after a while (appr. 1 minute) without an error-
> message:
>
> // Loop 12 Times:
> $conn=odbc_connect("database1","","");
> $sql="SELECT * FROM Table1 WHERE id>0";
> $result = odbc_exec($conn, $sql);
> $i=1;
> while (odbc_fetch_row($result, $i)){
> // --- Creating table for display ---
> $i++;
> };
>
> With reading 3000 records, looping 12 times. With the loop ~ 1 to 3
> times the script works.
>
> Is there any timeout-problem (session- and script-timeout are set to
> 1000)?
>
> Regards
> LK
>
A wild guess: Runs out of memory somewhere..

Re: Don"t get all records from SQL-table

am 24.09.2007 12:43:17 von LK

Thanks!

Error found: max_execution_time in php.ini was to short.



On 24 Sep., 10:11, LK wrote:
> Hi!
>
> Following script stops after a while (appr. 1 minute) without an error-
> message:
>
> // Loop 12 Times:
> $conn=odbc_connect("database1","","");
> $sql="SELECT * FROM Table1 WHERE id>0";
> $result = odbc_exec($conn, $sql);
> $i=1;
> while (odbc_fetch_row($result, $i)){
> // --- Creating table for display ---
> $i++;
> };
>
> With reading 3000 records, looping 12 times. With the loop ~ 1 to 3
> times the script works.
>
> Is there any timeout-problem (session- and script-timeout are set to
> 1000)?
>
> Regards
> LK

Re: Don"t get all records from SQL-table

am 24.09.2007 12:43:17 von LK

Thanks!

Error found: max_execution_time in php.ini was to short.



On 24 Sep., 10:11, LK wrote:
> Hi!
>
> Following script stops after a while (appr. 1 minute) without an error-
> message:
>
> // Loop 12 Times:
> $conn=odbc_connect("database1","","");
> $sql="SELECT * FROM Table1 WHERE id>0";
> $result = odbc_exec($conn, $sql);
> $i=1;
> while (odbc_fetch_row($result, $i)){
> // --- Creating table for display ---
> $i++;
> };
>
> With reading 3000 records, looping 12 times. With the loop ~ 1 to 3
> times the script works.
>
> Is there any timeout-problem (session- and script-timeout are set to
> 1000)?
>
> Regards
> LK