Jump to content
Sign in to follow this  
OS_Tim

Datarow Help with Modified Multi Product Update

Recommended Posts

I'm working with the multiproduct update data row tables. Right now I'm using the following query and data rows to display my results:

 

$updates_raw = "select p.vendors_id, p.products_id, p.products_quantity, p.products_price, p.products_msrp, p.products_model, pd.products_name, ps.products_stock_id, ps.products_id from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_PRODUCTS_STOCK . " ps where p.products_id = pd.products_id and p.products_id = ps.products_id and p.vendors_id = '" . (int)$vendors_id . "' group by p.products_id order by $order";

 

			  <tr class="dataTableRow">
			<td class="dataTableContent"><?php echo $row['products_id'] . "<input type='hidden' name='event_record[" . $id . "][products_id]' value='".$id."'>"; ?></td>
														<td class="dataTableContent"><?php echo $row['products_stock_id'] . "<input type='hidden' name='event_record[" . $sid . "][products_stock_id]' value='".$sid."'>"; ?></td>																						  
			<td class="dataTableContent"><?php echo $row['products_model']; ?></td>
		   <td class="dataTableContent"><?php echo '<a href="http://smallofficesolutions.info/clients/associates/supplier/supplier_s_categories_products.php?&
' . ('pID=' . $row['products_id']) . '&action=new_product' . '"><u>' . $row['products_name'] . '</u></a>'; ?></td>
			<td class="dataTableContent"><?php echo tep_draw_input_field('event_record[' . $id . '][products_quantity]', $row['products_quantity'], 'size="6"'); ?></td>																																 
			<td class="dataTableContent"><?php echo $row['products_price']; ?></td>
			<td class="dataTableContent"><?php echo $row['products_msrp']; ?></td>																													 
		  </tr>

 

This will return in each row all products that HAVE a products_stock_id, the products which are using QTPro to keep track of stock by attributes. This is great, but I also need to know how to use the above to display all products that DO NOT have products_stock_id. I think there would be any easy way to do this but can't figure it out.

 

TIA

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×