- $sql= "SELECT COUNT(*) FROM ".TB_PREF."company WHERE debtors_act='$selected_account'
- OR pyt_discount_act='$selected_account'
- OR creditors_act='$selected_account'
- OR freight_act='$selected_account'
- OR default_sales_act='$selected_account'
- OR default_sales_discount_act='$selected_account'
- OR default_prompt_payment_act='$selected_account'
- OR default_inventory_act='$selected_account'
- OR default_cogs_act='$selected_account'
- OR default_adj_act='$selected_account'
- OR default_inv_sales_act='$selected_account'
- OR default_assembly_act='$selected_account'";
- $result = db_query($sql,"Couldn't test for default company GL codes");
-
- $myrow = db_fetch_row($result);
- if ($myrow[0] > 0)