mongodb\ActiveRecord primaryKey()

primaryKey() public static method

Returns the primary key name(s) for this AR class.

The default implementation will return ['_id'].

Note that an array should be returned even for a collection with single primary key.

public static string[] primaryKey ( )
return string[]

The primary keys of the associated Mongo collection.

doc_Yii
2016-10-30 17:07:28
Comments
Leave a Comment

Please login to continue.