T
|
thamestrader 2/19/2018 |
When I had error 256 it was because my SQL statement was incorrectly coded. You don't say what database you are using, but SQL database managers have the ability to execute SQL statements inactively, have you tried the Select statement on the detail table to see what format the output takes? I doubt it will be a single numeric value and there will doubtless be a column heading before it. You are relying on the DBLOOKUP formatting the output from the SQL into a single numeric value to populate the variable so it can be used in the UPDATE SQL. |
![]() |
Admin 2/19/2018 |
You need to print your SQL queries on the page instead of executing them to see what exactly is wrong. |
M
|
mersintarim 2/19/2018 |
try this |
C
|
casuva author 2/20/2018 |
You need to print your SQL queries on the page instead of executing them to see what exactly is wrong.
|
![]() |
Admin 2/20/2018 |
Instead of $sum1 = DBLookup("Select SUM(kapanis_km-acilis_km) AS toplamkm from arac_gorev where FK_araclar = ".$values["id"]);
echo("Select SUM(kapanis_km-acilis_km) AS toplamkm from arac_gorev where FK_araclar = ".$values["id"]); |
M
|
mersintarim 2/20/2018 |
for print(monitor) sql query results |
C
|
casuva author 2/20/2018 |
Instead of $sum1 = DBLookup("Select SUM(kapanis_km-acilis_km) AS toplamkm from arac_gorev where FK_araclar = ".$values["id"]);
echo("Select SUM(kapanis_km-acilis_km) AS toplamkm from arac_gorev where FK_araclar = ".$values["id"]);
echo("Select SUM(kapanis_km-acilis_km) AS toplamkm from arac_gorev where FK_araclar = ".$values["id"]);
|
![]() |
Admin 2/20/2018 |
Run this printed query in a tool like phpMyAdmin. Make sure it runs and it returns correct results. |
C
|
casuva author 2/21/2018 |
Solved |