数组资料操作

WBOY
Release: 2016-06-13 12:38:40
Original
1120 people have browsed it

数组文件操作

本帖最后由 lazygc520 于 2013-09-05 13:13:44 编辑 已知数组a和数组b
<br />
$a = array (<br />
 0 => <br />
  array (<br />
    'cust_no' => '310F6 1VA5A',<br />
    'lotno' => '2X15',<br />
    'count' => '0',<br />
  ),<br />
  1 => <br />
  array (<br />
    'cust_no' => '310F6 1VA5A',<br />
    'lotno' => '2Z15',<br />
    'count' => '16',<br />
  ),<br />
);<br />
<br />
$b = array (<br />
  0 => <br />
  array (<br />
    'cust_no' => '310F6 1VA5A',<br />
    'lotno' => '2X15',<br />
    'count' => '0',<br />
  ),<br />
  1 => <br />
  array (<br />
    'cust_no' => '310F6 1VA5A',<br />
    'lotno' => '2Z15',<br />
    'count' => '32',<br />
  ),<br />
  2 => <br />
  array (<br />
    'cust_no' => '310F6 1VA5A',<br />
    'lotno' => '3528',<br />
    'count' => '80',<br />
  ),<br />
);<br />
Copy after login


想要得到的结果是当数组b和数组a的cust_no和lotno都相同时,则提示update table sql
否则insert table sql。请问怎么求?

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template