ORDER_REF的问题

Discussion in 'CTP' started by jmonroe2010, Feb 8, 2010.

  1. 在TraderSpi.cpp,
    int iNextOrderRef = atoi(pRspUserLogin->MaxOrderRef);
    iNextOrderRef++;
    sprintf(ORDER_REF, "%d", iNextOrderRef);

    请问ORDER_REF应该怎样生成?登陆后的第一个order是pRspUserLogin->MaxOrderRef, 然后第二个order是在第一个ORDER_REF上加1, 以此类推吗?另外第一个order一定是pRspUserLogin->MaxOrderRef吗?我自己知道一个整数可以吗? 第一第二第三个order的ORDER_REF一定是连续的吗?
    谢谢
     
  2. 客户端只要保证orderref字段递增就行,递增幅度可以取任意整数值,且不要求每次的递增幅度相同。