Skip to content

Instantly share code, notes, and snippets.

@romkaspb
Created May 25, 2017 10:17
Show Gist options
  • Save romkaspb/e0672ac07119fbf06701cc45c7c4c1c6 to your computer and use it in GitHub Desktop.
Save romkaspb/e0672ac07119fbf06701cc45c7c4c1c6 to your computer and use it in GitHub Desktop.
$where = " startdate ... " #или что там у тебя
$where .= " AND ((salestype = 0 and salescode=$userCode) OR (salestype=1 and salescode=$userGr) OR (salestype=2))"
$sql = $self->dbi->query("select * from dtbl_catalog_items_prices where $where order by salestype")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment